Re: How to draw graphics to a high resolution and high refresh rate monitor with vsync?
Posted: Mon Dec 15, 2025 12:12 pm
Next discovery...
In the command streaming PRM ~pg. 49, there is a table defining what the context image should look like, which includes NOOPS, headers and register/value pairs.
The header words shown are actually opcodes, with what appears to be some undocumented opcode structure.
The table for example shows 0x1108_1019 which looks like a magic value but it's not.
This is the MI_LOAD_REG_IMMEDIATE instruction.
The opcode is 0x22 at bit 23, then there are two undocumented bits:
MMIO (bit 19)
POSTED (bit 12)
the low 8 bits is a formula for the number of reg/value pairs that follow and it's value is (2 * regCount - 1) & 0xff.
So the example in the PRM is saying load 25 register pairs.
I'm assuming the table is really just more of an example, and the registers your chose to load are up to you to some extent, with a typical example provided for GTT mode and PPGTT mode.
In the command streaming PRM ~pg. 49, there is a table defining what the context image should look like, which includes NOOPS, headers and register/value pairs.
The header words shown are actually opcodes, with what appears to be some undocumented opcode structure.
The table for example shows 0x1108_1019 which looks like a magic value but it's not.
This is the MI_LOAD_REG_IMMEDIATE instruction.
The opcode is 0x22 at bit 23, then there are two undocumented bits:
MMIO (bit 19)
POSTED (bit 12)
the low 8 bits is a formula for the number of reg/value pairs that follow and it's value is (2 * regCount - 1) & 0xff.
So the example in the PRM is saying load 25 register pairs.
I'm assuming the table is really just more of an example, and the registers your chose to load are up to you to some extent, with a typical example provided for GTT mode and PPGTT mode.