Method numbers are 3D engine (subchannel 0) word offsets, and macro calls are methods 0xe00 + 2*index.
| Method | Use seen in NVN command memory |
|---|---|
0x004-0x007 | puller semaphore address, payload and operation (release writes memory, acquire reads) |
0x3e0, 0x68b | written with zero (cache flush and no-op forms, no memory effect) |
0x4eb | window origin. Game A's queue tail changes it from 0 to 0x10 after the first submission |
0x5f2, 0x5f6 | index buffer address (two words) and index type, before macro 38 |
0x6c0-0x6c3 | query address, sequence and report operation |
0x701, 0x702, 0x7c0, 0x7c1 | vertex stream 0 start address and inclusive end |
0x8e0-0x8e3 | constant buffer size, address and write offset |
0x8e4-0x8f3 | constant buffer data |
0x904 + 8*stage | constant buffer bank bind (0x904 vertex, 0x924 fragment) |
| Macro | Method | Observed meaning |
|---|---|---|
| 7 | 0xe0e | IMMD call with the shader stage, at the start of BindTexture: selects the stage's constant buffer (size from scratch 0xd2f + stage, address from 0xd2a + stage) for the handle written next |
| 8 | 0xe10 | blend enables of the eight render targets from bits 8-15 of its argument, after a zero to 0x671 |
| 9 | 0xe12 | the eight render targets' color masks (0x680-0x687), two 13-bit halves per argument |
| 12 | 0xe18 | program bind, five arguments. Selector 1 writes VertexB's code offset, 5 the fragment's, and the third argument is the offset (game B MME trace) |
| 16 | 0xe20 | sets a constant buffer write offset in words: 0x154 before a storage descriptor upload of three 0x8e4 words landed at bank 0 + 0x550. In game B it began at word 0xfe of the uploaded MME program |
| 25 | 0xe32 | DrawArrays (mode, first, count) |
| 27, 37 | 0xe36, 0xe4a | instanced draw: topology, vertex count, instance count (masked by scratch 0xd1b), first vertex, base instance. 37 also writes the base instance into the bound constant buffer at 0x644 |
| 30 | 0xe3c | instanced indexed draw, game B's busiest macro: topology, index count, instance count (masked by 0xd1b), first index, base vertex, base instance |
| 35 | 0xe46 | writes scratch 0xd38-0xd39, then 0x0d8-0x0d9, from two arguments and scratch 0xd3a |
| 28 | 0xe38 | DrawElements (mode, index address high and low, index type, count) |
| 26, 29 | 0xe34, 0xe3a | DrawArraysIndirect and DrawElementsIndirect of NVN 55.15 (one game): after macro 16 with 0x190 (bank 0 + 0x640), the mode and the record, which the driver splices into the pushbuffer from its GPU address. A capture of the Maxwell path showed the record's base instance at bank 0 + 0x644. nvn's indirect draws give the vertex program BaseVertex and BaseInstance there (DrawCall.params) |
| 38 | 0xe4c | the 12-word indexed draw in game B secondary lists: IMMD 0xe20 (value 0x190, the base vertex word), index type, index address, then six arguments. Packet word 10 (the fifth argument) is the base vertex |
Slot numbers are game B's and those written by the studied functions. Another title's upload can number them differently. Register writes made inside a macro are not visible in the pushbuffer, so shader and constant buffer state cannot be inferred from direct writes alone.
Made from docs/layers/gpu/nvn.md at 69237645142c. GPL-3.0-or-later.