shader: add NGG pass-through lowering dropping LDS round-trip in gfx2hlsl (Part of #1723) #2089

Closed
tedin7 wants to merge 15 commits from upstream-pr/2096 into main
tedin7 commented 2026-11-25 00:14:01 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T00:14:01Z.


Part of #1723

What this unblocks: NGG pass-through vertex shaders (the largest refusal in the startup batch, 846 of 1,171 pairs) can now be translated instead of refused.

Changes in tools/startup/gfx2hlsl.py:

  • s_sendmsg GS_ALLOC_REQ and s_barrier are accepted as no-ops in a straight-line vertex shader with entry EXEC.
  • ds_write_b32 / ds_read_b32 round trip: forwarded to a register copy only when the address is proven lane-private: stride * lane + offset built from v_mbcnt, aligned, inside 64 KiB, and every write checked disjoint from every earlier write across all lane pairs. Aliasing, non-affine and entry-v0 addresses, reads of unwritten or stale slots and any other LDS form stay refused.
  • Position and parameter exports are unchanged.
  • Primitive export (exp prim / target_20) is accepted only as one uncompressed VGPR0 word, with VGPR0 never written. Any other primitive export is refused as non-identity primitive export.

New test: tests/startup_gfx2hlsl_ngg_passthrough_check.py, registered in CMakeLists.txt as startup_gfx2hlsl_ngg_passthrough. It covers the accepted round trip, offset separation, the kept position export, and negative controls (computed or other-register primitive word, extra channels, compressed, after a branch, unwritten/stale/changed slots, unknown message, pixel shader, branch).

Source: AMD RDNA 2 Instruction Set Architecture guide, LDS (DS) instructions and the s_sendmsg GS_ALLOC_REQ message sections; the lane id as read by v_mbcnt_lo/hi (Vector ALU section).

Verification:

  • python3 -I -B tests/startup_gfx2hlsl_ngg_passthrough_check.py -> all ok
  • all tests/startup_gfx2hlsl_*_check.py run locally on Linux -> all pass
  • Win2025 commands: not run in this session (Linux only); CI to confirm.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:6594121641 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T00:14:01Z. --- Part of #1723 What this unblocks: NGG pass-through vertex shaders (the largest refusal in the startup batch, 846 of 1,171 pairs) can now be translated instead of refused. Changes in `tools/startup/gfx2hlsl.py`: - `s_sendmsg` GS_ALLOC_REQ and `s_barrier` are accepted as no-ops in a straight-line vertex shader with entry EXEC. - `ds_write_b32` / `ds_read_b32` round trip: forwarded to a register copy only when the address is proven lane-private: `stride * lane + offset` built from `v_mbcnt`, aligned, inside 64 KiB, and every write checked disjoint from every earlier write across all lane pairs. Aliasing, non-affine and entry-`v0` addresses, reads of unwritten or stale slots and any other LDS form stay refused. - Position and parameter exports are unchanged. - Primitive export (`exp prim` / `target_20`) is accepted only as one uncompressed VGPR0 word, with VGPR0 never written. Any other primitive export is refused as `non-identity primitive export`. New test: `tests/startup_gfx2hlsl_ngg_passthrough_check.py`, registered in `CMakeLists.txt` as `startup_gfx2hlsl_ngg_passthrough`. It covers the accepted round trip, offset separation, the kept position export, and negative controls (computed or other-register primitive word, extra channels, compressed, after a branch, unwritten/stale/changed slots, unknown message, pixel shader, branch). Source: AMD RDNA 2 Instruction Set Architecture guide, LDS (DS) instructions and the s_sendmsg GS_ALLOC_REQ message sections; the lane id as read by v_mbcnt_lo/hi (Vector ALU section). Verification: - `python3 -I -B tests/startup_gfx2hlsl_ngg_passthrough_check.py` -> all ok - all `tests/startup_gfx2hlsl_*_check.py` run locally on Linux -> all pass - Win2025 commands: not run in this session (Linux only); CI to confirm. AI-assisted; commands listed were executed locally.
chatgpt-codex-connector[bot commented 2026-11-25 01:01:39 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T00:22:56Z.

Review: COMMENTED


💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 84b7c144cc

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6049619332 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#pullrequestreview-6049619332). Originally posted by [chatgpt-codex-connector[bot]](https://github.com/chatgpt-codex-connector%5Bbot%5D) on 2026-11-25T00:22:56Z. **Review:** COMMENTED --- <!-- codex-review-receipt:v1 --> ### 💡 Codex Review Here are some automated review suggestions for this pull request. **Reviewed commit:** `84b7c144cc` <details> <summary>ℹ️ About Codex in GitHub</summary> <br/> [Your team has set up Codex to review pull requests in this repo](https://chatgpt.com/codex/cloud/settings/general). Reviews are triggered when you - Open a pull request for review - Mark a draft as ready - Comment "@codex review". If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". </details>
chatgpt-codex-connector[bot commented 2026-11-25 01:02:04 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T00:14:10Z.


Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-25T00:22:59.522819Z 84b7c14 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7148293877 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7148293877). Originally posted by [chatgpt-codex-connector[bot]](https://github.com/chatgpt-codex-connector%5Bbot%5D) on 2026-11-25T00:14:10Z. --- <!-- codex-pull-request-review-summary --> <!-- codex-review-state:v1 {"code_review":{"commit_sha":"84b7c144cc019f20fd1915ff74ba9492566421ab","has_any_findings":true,"has_unresolved_findings":true,"status":"completed"},"security_review":{"commit_sha":null,"has_any_findings":null,"has_unresolved_findings":null,"status":null}} --> <details> <summary><strong>Codex Review Summary</strong>: ✅ Completed</summary> This comment shows the latest Codex review activity on this pull request. | Review | Status | Commit | Review trigger | | --- | --- | --- | --- | | 📝 **Code Review** | ✅ **Completed** <relative-time datetime="2026-11-25T00:22:59.522819Z">2026-11-25T00:22:59.522819Z</relative-time> | `84b7c14` | PR opened | <details> <summary>ℹ️ About Codex in GitHub</summary> <br/> [Your team has set up Codex to review pull requests in this repo](https://chatgpt.com/codex/cloud/settings/general). Reviews are triggered when you - Open a pull request for review - Mark a draft as ready - Comment "@codex review" or "@codex security review". Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. </details> </details>
chatgpt-codex-connector[bot commented 2026-11-25 01:02:17 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T00:22:56Z.

Code review location: tools/startup/gfx2hlsl.py; line 1495

@@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods):
         dst = reg_range(ops[0])[1]
         self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1]))
 
+    # ---- NGG vertex pass-through ---------------------------------------------------------------
+    # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS,
+    # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D
+    # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot
+    # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a
+    # slot read before it is written, a slot that another write or a register change made stale, an address proven
+    # the same for every lane (the lanes would share one slot) and any other LDS form.
+    GS_ALLOC_REQ = 9
+
+    def ngg_stage(self, what):
+        if self.kind != 'vs' or self.has_branches or not self.exec_known:
+            raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what)
+
+    def op_s_sendmsg(self, ops, mods):
+        self.ngg_stage('s_sendmsg')
+        try:
+            message = int(ops[0], 0) if len(ops) == 1 and not mods else None
+        except ValueError:
+            message = None
+        if message is None or message & 0xffff != self.GS_ALLOC_REQ:
+            raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods))
+        return None
+
+    def op_s_barrier(self, ops, mods):
+        self.ngg_stage('s_barrier')
+        return None
+
+    def lds_slot(self, ops, mods, count):
+        if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]):
+            raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods))
+        regs = [reg_range(o) for o in ops]
+        if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs):
+            raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods))
+        return [r[1] for r in regs], int(mods[0][7:])
+
+    def op_ds_write_b32(self, ops, mods):
+        self.ngg_stage('ds_write_b32')
+        (addr, data), offset = self.lds_slot(ops, mods, 2)
+        if addr in getattr(self, 'uniform_v', ()):
+            raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr)
+        slots = self.__dict__.setdefault('lds', {})
+        slots[(addr, offset)] = (self.v_version(addr), data, self.v_version(data))

P1 Badge Invalidate cached LDS slots on potentially aliasing writes

If a straight-line VS sets v1 = 4 * lane and copies it to v4, then writes one value through v1, writes another through v4 at the same offset, and reads through v1, this cache still forwards the first value. Both register versions remain unchanged, but the second write overwrote the same LDS word; a decoded synthetic fixture is accepted by Pipeline and miscomputes the exported value. Before retaining old entries across a write, prove its effective address is disjoint or invalidate/refuse potentially aliased slots.

Useful? React with 👍 / 👎.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688470748 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688470748). Originally posted by [chatgpt-codex-connector[bot]](https://github.com/chatgpt-codex-connector%5Bbot%5D) on 2026-11-25T00:22:56Z. **Code review location:** `tools/startup/gfx2hlsl.py`; line 1495 ~~~~diff @@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods): dst = reg_range(ops[0])[1] self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1])) + # ---- NGG vertex pass-through --------------------------------------------------------------- + # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS, + # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D + # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot + # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a + # slot read before it is written, a slot that another write or a register change made stale, an address proven + # the same for every lane (the lanes would share one slot) and any other LDS form. + GS_ALLOC_REQ = 9 + + def ngg_stage(self, what): + if self.kind != 'vs' or self.has_branches or not self.exec_known: + raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what) + + def op_s_sendmsg(self, ops, mods): + self.ngg_stage('s_sendmsg') + try: + message = int(ops[0], 0) if len(ops) == 1 and not mods else None + except ValueError: + message = None + if message is None or message & 0xffff != self.GS_ALLOC_REQ: + raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods)) + return None + + def op_s_barrier(self, ops, mods): + self.ngg_stage('s_barrier') + return None + + def lds_slot(self, ops, mods, count): + if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]): + raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods)) + regs = [reg_range(o) for o in ops] + if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs): + raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods)) + return [r[1] for r in regs], int(mods[0][7:]) + + def op_ds_write_b32(self, ops, mods): + self.ngg_stage('ds_write_b32') + (addr, data), offset = self.lds_slot(ops, mods, 2) + if addr in getattr(self, 'uniform_v', ()): + raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr) + slots = self.__dict__.setdefault('lds', {}) + slots[(addr, offset)] = (self.v_version(addr), data, self.v_version(data)) ~~~~ --- **<sub><sub>![P1 Badge](https://img.shields.io/badge/P1-orange?style=flat)</sub></sub> Invalidate cached LDS slots on potentially aliasing writes** If a straight-line VS sets `v1 = 4 * lane` and copies it to `v4`, then writes one value through `v1`, writes another through `v4` at the same offset, and reads through `v1`, this cache still forwards the first value. Both register versions remain unchanged, but the second write overwrote the same LDS word; a decoded synthetic fixture is accepted by `Pipeline` and miscomputes the exported value. Before retaining old entries across a write, prove its effective address is disjoint or invalidate/refuse potentially aliased slots. Useful? React with 👍 / 👎. <!-- codex-code-review-finding:v1 -->
chatgpt-codex-connector[bot commented 2026-11-25 01:02:17 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T00:22:56Z.

Code review location: tools/startup/gfx2hlsl.py; line 1493

@@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods):
         dst = reg_range(ops[0])[1]
         self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1]))
 
+    # ---- NGG vertex pass-through ---------------------------------------------------------------
+    # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS,
+    # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D
+    # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot
+    # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a
+    # slot read before it is written, a slot that another write or a register change made stale, an address proven
+    # the same for every lane (the lanes would share one slot) and any other LDS form.
+    GS_ALLOC_REQ = 9
+
+    def ngg_stage(self, what):
+        if self.kind != 'vs' or self.has_branches or not self.exec_known:
+            raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what)
+
+    def op_s_sendmsg(self, ops, mods):
+        self.ngg_stage('s_sendmsg')
+        try:
+            message = int(ops[0], 0) if len(ops) == 1 and not mods else None
+        except ValueError:
+            message = None
+        if message is None or message & 0xffff != self.GS_ALLOC_REQ:
+            raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods))
+        return None
+
+    def op_s_barrier(self, ops, mods):
+        self.ngg_stage('s_barrier')
+        return None
+
+    def lds_slot(self, ops, mods, count):
+        if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]):
+            raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods))
+        regs = [reg_range(o) for o in ops]
+        if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs):
+            raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods))
+        return [r[1] for r in regs], int(mods[0][7:])
+
+    def op_ds_write_b32(self, ops, mods):
+        self.ngg_stage('ds_write_b32')
+        (addr, data), offset = self.lds_slot(ops, mods, 2)
+        if addr in getattr(self, 'uniform_v', ()):
+            raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr)

P1 Badge Prove that LDS addresses are lane-private before forwarding

In a multi-lane straight-line VS, v_and_b32_e32 v1, 0, v0 makes every lane's address zero, but v1 is absent from uniform_v because that operation is outside UNIFORM_VALU. This therefore accepts ds_write_b32 v1, v0 offset:16 followed by a wait/barrier and ds_read_b32 v3, v1 offset:16, lowering the read to v3 = v0. The actual read accesses one shared word and must return the same stored value to every lane, whereas the translation returns different values. Absence of a uniformity proof is not proof of lane-private addressing; require a positive non-overlap proof before eliminating LDS.

Useful? React with 👍 / 👎.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688470756 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688470756). Originally posted by [chatgpt-codex-connector[bot]](https://github.com/chatgpt-codex-connector%5Bbot%5D) on 2026-11-25T00:22:56Z. **Code review location:** `tools/startup/gfx2hlsl.py`; line 1493 ~~~~diff @@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods): dst = reg_range(ops[0])[1] self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1])) + # ---- NGG vertex pass-through --------------------------------------------------------------- + # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS, + # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D + # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot + # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a + # slot read before it is written, a slot that another write or a register change made stale, an address proven + # the same for every lane (the lanes would share one slot) and any other LDS form. + GS_ALLOC_REQ = 9 + + def ngg_stage(self, what): + if self.kind != 'vs' or self.has_branches or not self.exec_known: + raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what) + + def op_s_sendmsg(self, ops, mods): + self.ngg_stage('s_sendmsg') + try: + message = int(ops[0], 0) if len(ops) == 1 and not mods else None + except ValueError: + message = None + if message is None or message & 0xffff != self.GS_ALLOC_REQ: + raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods)) + return None + + def op_s_barrier(self, ops, mods): + self.ngg_stage('s_barrier') + return None + + def lds_slot(self, ops, mods, count): + if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]): + raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods)) + regs = [reg_range(o) for o in ops] + if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs): + raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods)) + return [r[1] for r in regs], int(mods[0][7:]) + + def op_ds_write_b32(self, ops, mods): + self.ngg_stage('ds_write_b32') + (addr, data), offset = self.lds_slot(ops, mods, 2) + if addr in getattr(self, 'uniform_v', ()): + raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr) ~~~~ --- **<sub><sub>![P1 Badge](https://img.shields.io/badge/P1-orange?style=flat)</sub></sub> Prove that LDS addresses are lane-private before forwarding** In a multi-lane straight-line VS, `v_and_b32_e32 v1, 0, v0` makes every lane's address zero, but `v1` is absent from `uniform_v` because that operation is outside `UNIFORM_VALU`. This therefore accepts `ds_write_b32 v1, v0 offset:16` followed by a wait/barrier and `ds_read_b32 v3, v1 offset:16`, lowering the read to `v3 = v0`. The actual read accesses one shared word and must return the same stored value to every lane, whereas the translation returns different values. Absence of a uniformity proof is not proof of lane-private addressing; require a positive non-overlap proof before eliminating LDS. Useful? React with 👍 / 👎. <!-- codex-code-review-finding:v1 -->
chatgpt-codex-connector[bot commented 2026-11-25 01:02:17 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T00:22:56Z.

Code review location: CMakeLists.txt; line 2520

@@ -2515,6 +2515,9 @@ if(EXISTS "${INTAKE_PYTHON}")
     # Startup shader translator: uniform sources of v_readfirstlane_b32 in straight-line code (#1723).
     add_test(NAME startup_gfx2hlsl_readfirstlane_uniform COMMAND "${INTAKE_PYTHON}" -B
         "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_readfirstlane_uniform_check.py")
+    # Startup shader translator: NGG vertex pass-through, LDS round trip dropped (#1723).
+    add_test(NAME startup_gfx2hlsl_ngg_passthrough COMMAND "${INTAKE_PYTHON}" -B
+        "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_ngg_passthrough_check.py")

P1 Badge Document the new NGG translation capability and test command

This introduces public NGG translation support, but neither the README nor docs/experiments.md is updated, contrary to AGENTS.md's requirement to update capability documentation when a public capability or reproduction command changes. The existing NGG experiment section documents the older classification fixture, not this accepted straight-line profile or its regression check. Document the supported/refused cases and the reproduction command python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py.

AGENTS.md reference: AGENTS.md:L223-L224

Useful? React with 👍 / 👎.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688470761 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688470761). Originally posted by [chatgpt-codex-connector[bot]](https://github.com/chatgpt-codex-connector%5Bbot%5D) on 2026-11-25T00:22:56Z. **Code review location:** `CMakeLists.txt`; line 2520 ~~~~diff @@ -2515,6 +2515,9 @@ if(EXISTS "${INTAKE_PYTHON}") # Startup shader translator: uniform sources of v_readfirstlane_b32 in straight-line code (#1723). add_test(NAME startup_gfx2hlsl_readfirstlane_uniform COMMAND "${INTAKE_PYTHON}" -B "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_readfirstlane_uniform_check.py") + # Startup shader translator: NGG vertex pass-through, LDS round trip dropped (#1723). + add_test(NAME startup_gfx2hlsl_ngg_passthrough COMMAND "${INTAKE_PYTHON}" -B + "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_ngg_passthrough_check.py") ~~~~ --- **<sub><sub>![P1 Badge](https://img.shields.io/badge/P1-orange?style=flat)</sub></sub> Document the new NGG translation capability and test command** This introduces public NGG translation support, but neither the README nor `docs/experiments.md` is updated, contrary to `AGENTS.md`'s requirement to update capability documentation when a public capability or reproduction command changes. The existing NGG experiment section documents the older classification fixture, not this accepted straight-line profile or its regression check. Document the supported/refused cases and the reproduction command `python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py`. AGENTS.md reference: [AGENTS.md:L223-L224](https://github.com/R0Y00/Xbox2Windows/blob/84b7c144cc019f20fd1915ff74ba9492566421ab/AGENTS.md#L223-L224) Useful? React with 👍 / 👎. <!-- codex-code-review-finding:v1 -->
chatgpt-codex-connector[bot commented 2026-11-25 01:02:17 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by chatgpt-codex-connector[bot] on 2026-11-25T00:22:56Z.

Code review location: tools/startup/gfx2hlsl.py; line 1482

@@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods):
         dst = reg_range(ops[0])[1]
         self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1]))
 
+    # ---- NGG vertex pass-through ---------------------------------------------------------------
+    # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS,
+    # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D
+    # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot
+    # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a
+    # slot read before it is written, a slot that another write or a register change made stale, an address proven
+    # the same for every lane (the lanes would share one slot) and any other LDS form.
+    GS_ALLOC_REQ = 9
+
+    def ngg_stage(self, what):
+        if self.kind != 'vs' or self.has_branches or not self.exec_known:
+            raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what)
+
+    def op_s_sendmsg(self, ops, mods):
+        self.ngg_stage('s_sendmsg')
+        try:
+            message = int(ops[0], 0) if len(ops) == 1 and not mods else None
+        except ValueError:
+            message = None
+        if message is None or message & 0xffff != self.GS_ALLOC_REQ:
+            raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods))
+        return None
+
+    def op_s_barrier(self, ops, mods):
+        self.ngg_stage('s_barrier')
+        return None
+
+    def lds_slot(self, ops, mods, count):
+        if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]):

P2 Badge Default omitted DS offsets to zero

For encoded DS instructions whose immediate offset is zero, disasm_rdna2.decode_instruction() omits the modifier entirely, producing forms such as ds_write_b32 v2, v8 and ds_read_b32 v24, v2. Consequently parse() supplies an empty modifier list and this condition rejects an otherwise supported same-lane round trip. The new fixture only supplies explicit nonzero offsets, so it misses the decoder/parser mismatch. Accept an omitted offset as zero while continuing to reject unsupported modifiers.

Useful? React with 👍 / 👎.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688470772 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688470772). Originally posted by [chatgpt-codex-connector[bot]](https://github.com/chatgpt-codex-connector%5Bbot%5D) on 2026-11-25T00:22:56Z. **Code review location:** `tools/startup/gfx2hlsl.py`; line 1482 ~~~~diff @@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods): dst = reg_range(ops[0])[1] self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1])) + # ---- NGG vertex pass-through --------------------------------------------------------------- + # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS, + # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D + # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot + # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a + # slot read before it is written, a slot that another write or a register change made stale, an address proven + # the same for every lane (the lanes would share one slot) and any other LDS form. + GS_ALLOC_REQ = 9 + + def ngg_stage(self, what): + if self.kind != 'vs' or self.has_branches or not self.exec_known: + raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what) + + def op_s_sendmsg(self, ops, mods): + self.ngg_stage('s_sendmsg') + try: + message = int(ops[0], 0) if len(ops) == 1 and not mods else None + except ValueError: + message = None + if message is None or message & 0xffff != self.GS_ALLOC_REQ: + raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods)) + return None + + def op_s_barrier(self, ops, mods): + self.ngg_stage('s_barrier') + return None + + def lds_slot(self, ops, mods, count): + if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]): ~~~~ --- **<sub><sub>![P2 Badge](https://img.shields.io/badge/P2-yellow?style=flat)</sub></sub> Default omitted DS offsets to zero** For encoded DS instructions whose immediate offset is zero, `disasm_rdna2.decode_instruction()` omits the modifier entirely, producing forms such as `ds_write_b32 v2, v8` and `ds_read_b32 v24, v2`. Consequently `parse()` supplies an empty modifier list and this condition rejects an otherwise supported same-lane round trip. The new fixture only supplies explicit nonzero offsets, so it misses the decoder/parser mismatch. Accept an omitted offset as zero while continuing to reject unsupported modifiers. Useful? React with 👍 / 👎. <!-- codex-code-review-finding:v1 -->
tedin7 commented 2026-11-25 02:01:44 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:33Z.

Review: COMMENTED


No description provided.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6049977237 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#pullrequestreview-6049977237). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:33Z. **Review:** COMMENTED --- _No description provided._
tedin7 commented 2026-11-25 02:01:44 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:34Z.

Review: COMMENTED


No description provided.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6049977485 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#pullrequestreview-6049977485). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:34Z. **Review:** COMMENTED --- _No description provided._
tedin7 commented 2026-11-25 02:01:44 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:36Z.

Review: COMMENTED


No description provided.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6049977688 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#pullrequestreview-6049977688). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:36Z. **Review:** COMMENTED --- _No description provided._
tedin7 commented 2026-11-25 02:01:45 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:37Z.

Review: COMMENTED


No description provided.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6049977841 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#pullrequestreview-6049977841). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:37Z. **Review:** COMMENTED --- _No description provided._
tedin7 commented 2026-11-25 02:02:14 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:32Z.

Code review location: tools/startup/gfx2hlsl.py; line 1495

@@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods):
         dst = reg_range(ops[0])[1]
         self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1]))
 
+    # ---- NGG vertex pass-through ---------------------------------------------------------------
+    # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS,
+    # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D
+    # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot
+    # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a
+    # slot read before it is written, a slot that another write or a register change made stale, an address proven
+    # the same for every lane (the lanes would share one slot) and any other LDS form.
+    GS_ALLOC_REQ = 9
+
+    def ngg_stage(self, what):
+        if self.kind != 'vs' or self.has_branches or not self.exec_known:
+            raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what)
+
+    def op_s_sendmsg(self, ops, mods):
+        self.ngg_stage('s_sendmsg')
+        try:
+            message = int(ops[0], 0) if len(ops) == 1 and not mods else None
+        except ValueError:
+            message = None
+        if message is None or message & 0xffff != self.GS_ALLOC_REQ:
+            raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods))
+        return None
+
+    def op_s_barrier(self, ops, mods):
+        self.ngg_stage('s_barrier')
+        return None
+
+    def lds_slot(self, ops, mods, count):
+        if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]):
+            raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods))
+        regs = [reg_range(o) for o in ops]
+        if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs):
+            raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods))
+        return [r[1] for r in regs], int(mods[0][7:])
+
+    def op_ds_write_b32(self, ops, mods):
+        self.ngg_stage('ds_write_b32')
+        (addr, data), offset = self.lds_slot(ops, mods, 2)
+        if addr in getattr(self, 'uniform_v', ()):
+            raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr)
+        slots = self.__dict__.setdefault('lds', {})
+        slots[(addr, offset)] = (self.v_version(addr), data, self.v_version(data))

Fixed in 6fc39f2c: a ds_write now drops every cached slot whose address register differs or whose offset is within 4 bytes, so a write through a copied address can no longer leave a stale forward.
Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally.
AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688786248 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688786248). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:32Z. **Code review location:** `tools/startup/gfx2hlsl.py`; line 1495 ~~~~diff @@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods): dst = reg_range(ops[0])[1] self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1])) + # ---- NGG vertex pass-through --------------------------------------------------------------- + # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS, + # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D + # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot + # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a + # slot read before it is written, a slot that another write or a register change made stale, an address proven + # the same for every lane (the lanes would share one slot) and any other LDS form. + GS_ALLOC_REQ = 9 + + def ngg_stage(self, what): + if self.kind != 'vs' or self.has_branches or not self.exec_known: + raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what) + + def op_s_sendmsg(self, ops, mods): + self.ngg_stage('s_sendmsg') + try: + message = int(ops[0], 0) if len(ops) == 1 and not mods else None + except ValueError: + message = None + if message is None or message & 0xffff != self.GS_ALLOC_REQ: + raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods)) + return None + + def op_s_barrier(self, ops, mods): + self.ngg_stage('s_barrier') + return None + + def lds_slot(self, ops, mods, count): + if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]): + raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods)) + regs = [reg_range(o) for o in ops] + if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs): + raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods)) + return [r[1] for r in regs], int(mods[0][7:]) + + def op_ds_write_b32(self, ops, mods): + self.ngg_stage('ds_write_b32') + (addr, data), offset = self.lds_slot(ops, mods, 2) + if addr in getattr(self, 'uniform_v', ()): + raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr) + slots = self.__dict__.setdefault('lds', {}) + slots[(addr, offset)] = (self.v_version(addr), data, self.v_version(data)) ~~~~ --- Fixed in 6fc39f2c: a ds_write now drops every cached slot whose address register differs or whose offset is within 4 bytes, so a write through a copied address can no longer leave a stale forward. Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally. AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-25 02:02:14 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:34Z.

Code review location: tools/startup/gfx2hlsl.py; line 1493

@@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods):
         dst = reg_range(ops[0])[1]
         self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1]))
 
+    # ---- NGG vertex pass-through ---------------------------------------------------------------
+    # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS,
+    # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D
+    # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot
+    # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a
+    # slot read before it is written, a slot that another write or a register change made stale, an address proven
+    # the same for every lane (the lanes would share one slot) and any other LDS form.
+    GS_ALLOC_REQ = 9
+
+    def ngg_stage(self, what):
+        if self.kind != 'vs' or self.has_branches or not self.exec_known:
+            raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what)
+
+    def op_s_sendmsg(self, ops, mods):
+        self.ngg_stage('s_sendmsg')
+        try:
+            message = int(ops[0], 0) if len(ops) == 1 and not mods else None
+        except ValueError:
+            message = None
+        if message is None or message & 0xffff != self.GS_ALLOC_REQ:
+            raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods))
+        return None
+
+    def op_s_barrier(self, ops, mods):
+        self.ngg_stage('s_barrier')
+        return None
+
+    def lds_slot(self, ops, mods, count):
+        if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]):
+            raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods))
+        regs = [reg_range(o) for o in ops]
+        if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs):
+            raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods))
+        return [r[1] for r in regs], int(mods[0][7:])
+
+    def op_ds_write_b32(self, ops, mods):
+        self.ngg_stage('ds_write_b32')
+        (addr, data), offset = self.lds_slot(ops, mods, 2)
+        if addr in getattr(self, 'uniform_v', ()):
+            raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr)

Fixed in 6fc39f2c: the write address must now be proven lane-distinct (entry v0 or a plain v_mov copy of it); v_and with 0 and any other computed address is refused. New refusal cases added.
Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally.
AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688786467 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688786467). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:34Z. **Code review location:** `tools/startup/gfx2hlsl.py`; line 1493 ~~~~diff @@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods): dst = reg_range(ops[0])[1] self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1])) + # ---- NGG vertex pass-through --------------------------------------------------------------- + # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS, + # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D + # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot + # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a + # slot read before it is written, a slot that another write or a register change made stale, an address proven + # the same for every lane (the lanes would share one slot) and any other LDS form. + GS_ALLOC_REQ = 9 + + def ngg_stage(self, what): + if self.kind != 'vs' or self.has_branches or not self.exec_known: + raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what) + + def op_s_sendmsg(self, ops, mods): + self.ngg_stage('s_sendmsg') + try: + message = int(ops[0], 0) if len(ops) == 1 and not mods else None + except ValueError: + message = None + if message is None or message & 0xffff != self.GS_ALLOC_REQ: + raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods)) + return None + + def op_s_barrier(self, ops, mods): + self.ngg_stage('s_barrier') + return None + + def lds_slot(self, ops, mods, count): + if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]): + raise Unsupported('LDS access %s needs one VGPR address and an offset' % ' '.join(ops + mods)) + regs = [reg_range(o) for o in ops] + if any(not r or r[0] != 'v' or r[1] != r[2] for r in regs): + raise Unsupported('LDS access %s needs single VGPR operands' % ' '.join(ops + mods)) + return [r[1] for r in regs], int(mods[0][7:]) + + def op_ds_write_b32(self, ops, mods): + self.ngg_stage('ds_write_b32') + (addr, data), offset = self.lds_slot(ops, mods, 2) + if addr in getattr(self, 'uniform_v', ()): + raise Unsupported('ds_write_b32 address v%d is the same for every lane' % addr) ~~~~ --- Fixed in 6fc39f2c: the write address must now be proven lane-distinct (entry v0 or a plain v_mov copy of it); v_and with 0 and any other computed address is refused. New refusal cases added. Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally. AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-25 02:02:14 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:36Z.

Code review location: CMakeLists.txt; line 2520

@@ -2515,6 +2515,9 @@ if(EXISTS "${INTAKE_PYTHON}")
     # Startup shader translator: uniform sources of v_readfirstlane_b32 in straight-line code (#1723).
     add_test(NAME startup_gfx2hlsl_readfirstlane_uniform COMMAND "${INTAKE_PYTHON}" -B
         "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_readfirstlane_uniform_check.py")
+    # Startup shader translator: NGG vertex pass-through, LDS round trip dropped (#1723).
+    add_test(NAME startup_gfx2hlsl_ngg_passthrough COMMAND "${INTAKE_PYTHON}" -B
+        "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_ngg_passthrough_check.py")

Fixed in 6fc39f2c: docs/experiments.md now documents the NGG pass-through profile, refusals and the ctest/python reproduction commands.
Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally.
AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688786623 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688786623). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:36Z. **Code review location:** `CMakeLists.txt`; line 2520 ~~~~diff @@ -2515,6 +2515,9 @@ if(EXISTS "${INTAKE_PYTHON}") # Startup shader translator: uniform sources of v_readfirstlane_b32 in straight-line code (#1723). add_test(NAME startup_gfx2hlsl_readfirstlane_uniform COMMAND "${INTAKE_PYTHON}" -B "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_readfirstlane_uniform_check.py") + # Startup shader translator: NGG vertex pass-through, LDS round trip dropped (#1723). + add_test(NAME startup_gfx2hlsl_ngg_passthrough COMMAND "${INTAKE_PYTHON}" -B + "${CMAKE_CURRENT_SOURCE_DIR}/tests/startup_gfx2hlsl_ngg_passthrough_check.py") ~~~~ --- Fixed in 6fc39f2c: docs/experiments.md now documents the NGG pass-through profile, refusals and the ctest/python reproduction commands. Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally. AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-25 02:02:14 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T01:05:37Z.

Code review location: tools/startup/gfx2hlsl.py; line 1482

@@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods):
         dst = reg_range(ops[0])[1]
         self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1]))
 
+    # ---- NGG vertex pass-through ---------------------------------------------------------------
+    # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS,
+    # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D
+    # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot
+    # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a
+    # slot read before it is written, a slot that another write or a register change made stale, an address proven
+    # the same for every lane (the lanes would share one slot) and any other LDS form.
+    GS_ALLOC_REQ = 9
+
+    def ngg_stage(self, what):
+        if self.kind != 'vs' or self.has_branches or not self.exec_known:
+            raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what)
+
+    def op_s_sendmsg(self, ops, mods):
+        self.ngg_stage('s_sendmsg')
+        try:
+            message = int(ops[0], 0) if len(ops) == 1 and not mods else None
+        except ValueError:
+            message = None
+        if message is None or message & 0xffff != self.GS_ALLOC_REQ:
+            raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods))
+        return None
+
+    def op_s_barrier(self, ops, mods):
+        self.ngg_stage('s_barrier')
+        return None
+
+    def lds_slot(self, ops, mods, count):
+        if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]):

Fixed in 6fc39f2c: an omitted DS offset is parsed as offset 0; covered by a new test case.
Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally.
AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review-comment:4688786772 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#discussion_r4688786772). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T01:05:37Z. **Code review location:** `tools/startup/gfx2hlsl.py`; line 1482 ~~~~diff @@ -1441,6 +1451,61 @@ def op_v_cvt_i32_f32(self, ops, mods): dst = reg_range(ops[0])[1] self.set_v(dst, 'uint(int(F(%s)))' % self.u(ops[1])) + # ---- NGG vertex pass-through --------------------------------------------------------------- + # A pass-through NGG vertex shader asks for its allocation (s_sendmsg GS_ALLOC_REQ), parks per-lane values in LDS, + # synchronises (s_barrier), reads them back and exports the position, the parameters and the primitive word. D3D + # assembles the primitives itself, so the allocation request and the barrier have no effect here, and an LDS slot + # that the same lane writes and reads back is the register it was written from. Anything else stays refused: a + # slot read before it is written, a slot that another write or a register change made stale, an address proven + # the same for every lane (the lanes would share one slot) and any other LDS form. + GS_ALLOC_REQ = 9 + + def ngg_stage(self, what): + if self.kind != 'vs' or self.has_branches or not self.exec_known: + raise Unsupported('%s requires a straight-line vertex shader with entry EXEC' % what) + + def op_s_sendmsg(self, ops, mods): + self.ngg_stage('s_sendmsg') + try: + message = int(ops[0], 0) if len(ops) == 1 and not mods else None + except ValueError: + message = None + if message is None or message & 0xffff != self.GS_ALLOC_REQ: + raise Unsupported('s_sendmsg %s' % ' '.join(ops + mods)) + return None + + def op_s_barrier(self, ops, mods): + self.ngg_stage('s_barrier') + return None + + def lds_slot(self, ops, mods, count): + if len(ops) != count or len(mods) != 1 or not re.fullmatch(r'offset:\d+', mods[0]): ~~~~ --- Fixed in 6fc39f2c: an omitted DS offset is parsed as offset 0; covered by a new test case. Verification: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok); all 32 tests/startup_gfx2hlsl_*_check.py pass locally. AI-assisted; commands listed were executed locally.
R0Y00 commented 2026-11-25 13:00:37 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-25T12:25:34Z.

Review: CHANGES_REQUESTED


The LDS substitution still needs a cross-lane byte-range proof. At 29d2c2c8, lane_v records entry v0 and copies. It does not establish a stride or exclude another lane hitting a slot through a different immediate. For example, even if valid entry addresses are 4 bytes apart, lane A's v0 + 20 and lane B's v0 + 16 can name the same DWORD. The positive 16/20 fixture currently checks the emitted register assignments without exercising whether the source slots can alias.

Please either establish and enforce the entry address layout and prove the four-byte intervals disjoint across all active lanes and write offsets, or refuse the unproven LDS lowering. Add a control with distinct per-lane payloads and two aligned offsets that alias across lanes, plus a disjoint case.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6057558374 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#pullrequestreview-6057558374). Originally posted by [R0Y00](https://github.com/R0Y00) on 2026-11-25T12:25:34Z. **Review:** CHANGES_REQUESTED --- The LDS substitution still needs a cross-lane byte-range proof. At `29d2c2c8`, `lane_v` records entry v0 and copies. It does not establish a stride or exclude another lane hitting a slot through a different immediate. For example, even if valid entry addresses are 4 bytes apart, lane A's `v0 + 20` and lane B's `v0 + 16` can name the same DWORD. The positive 16/20 fixture currently checks the emitted register assignments without exercising whether the source slots can alias. Please either establish and enforce the entry address layout and prove the four-byte intervals disjoint across all active lanes and write offsets, or refuse the unproven LDS lowering. Add a control with distinct per-lane payloads and two aligned offsets that alias across lanes, plus a disjoint case.
upstream-sync closed this pull request 2026-11-25 14:04:42 +00:00
tedin7 commented 2026-11-25 14:05:12 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T13:50:26Z.


Closing this PR for now to keep the Windows test queue short. Nothing is wrong with it and the branch stays as it is.

We will reopen it once the queue is clear, re-run the Win2025 WARP checks at its head, and post the result here.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7164366653 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7164366653). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T13:50:26Z. --- Closing this PR for now to keep the Windows test queue short. Nothing is wrong with it and the branch stays as it is. We will reopen it once the queue is clear, re-run the Win2025 WARP checks at its head, and post the result here. AI-assisted; commands listed were executed locally.
upstream-sync reopened this pull request 2026-11-26 00:00:42 +00:00
tedin7 commented 2026-11-26 00:01:11 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T23:24:41Z.


Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit d909d5f8e47062971cfae47ce7b3c648c7c0edab:

  • Debug (--preset dev):
    • Build (cmake --build --preset dev --target offscreen_check -- -j 2): 1.49s (configure 0.00s)
    • Test (ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.11s: startup_gfx2hlsl_ngg_passthrough_warp 0.88s, startup_gfx2hlsl_ngg_passthrough_hardware 0.88s, startup_gfx2hlsl_ngg_passthrough 0.11s)
  • Release /O2 (--preset release):
    • Build (cmake --build --preset release --target offscreen_check -- -j 2): 1.15s (configure 0.00s)
    • Test (ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.32s: startup_gfx2hlsl_ngg_passthrough_warp 1.08s, startup_gfx2hlsl_ngg_passthrough_hardware 1.18s, startup_gfx2hlsl_ngg_passthrough 0.12s)
  • Windows Python checks: tests/startup_gfx2hlsl_ngg_passthrough_check.py ok (0.1s), tests/startup_gfx2hlsl_refusals_check.py ok (0.5s), tests/startup_ngg_slice_check.py ok (0.3s)
  • Wall: 9.8s

No separate physical-GPU result is claimed; the VM reports WARP.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7177522726 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7177522726). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T23:24:41Z. --- Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit `d909d5f8e47062971cfae47ce7b3c648c7c0edab`: - **Debug (`--preset dev`)**: - Build (`cmake --build --preset dev --target offscreen_check -- -j 2`): `1.49s` (configure `0.00s`) - Test (`ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.11s`: `startup_gfx2hlsl_ngg_passthrough_warp` `0.88s`, `startup_gfx2hlsl_ngg_passthrough_hardware` `0.88s`, `startup_gfx2hlsl_ngg_passthrough` `0.11s`) - **Release `/O2` (`--preset release`)**: - Build (`cmake --build --preset release --target offscreen_check -- -j 2`): `1.15s` (configure `0.00s`) - Test (`ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.32s`: `startup_gfx2hlsl_ngg_passthrough_warp` `1.08s`, `startup_gfx2hlsl_ngg_passthrough_hardware` `1.18s`, `startup_gfx2hlsl_ngg_passthrough` `0.12s`) - **Windows Python checks**: `tests/startup_gfx2hlsl_ngg_passthrough_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_refusals_check.py` ok (`0.5s`), `tests/startup_ngg_slice_check.py` ok (`0.3s`) - Wall: `9.8s` No separate physical-GPU result is claimed; the VM reports WARP. AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 00:01:11 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-25T23:25:59Z.


@R0Y00 @MasterDomino the LDS point is now handled by a proof, not a refusal. Head d909d5f8.

Your request: prove the four-byte intervals disjoint across all active lanes and write offsets, enforced in the translator, or refuse; add an aliasing control with distinct per-lane payloads and a disjoint case.

  • Layout enforced. The entry v0 is a packed word, so it is no longer accepted as a lane address. The address must be stride * lane + offset built from v_mbcnt_lo_u32_b32 v, -1, 0 + v_mbcnt_hi_u32_b32 v, -1, v (lane 0..63) by v_mov, v_lshlrev, v_add_nc, v_mul_u32_u24/v_mul_lo_u32, v_mad_u32_u24 with immediates. Stride and offset must be 4-byte aligned and stay inside 64 KiB for all 64 lanes.
  • Disjointness enforced. Every ds_write_b32 is checked against every earlier write and itself for all lane pairs (Stage.lds_overlap); any meeting is refused with the two strides and offsets named. A read takes the write with the identical form, and is refused if the payload register changed.
  • Aliasing control. Stride 4, offsets 16 and 20, distinct payloads v2/v8: refused (not disjoint). Mutation: with the overlap check replaced by False the same program is lowered, so the control fails without the check.
  • Disjoint case. Stride 8, offsets 0 and 4, distinct payloads: lowered to v3 = v2; v9 = v8;. Also lowered: stride 12 from a mad with a read through another register of equal form, and stride 4 with one offset.
  • Other controls refused: entry v0 and a copy of it, v_mbcnt_lo alone, stride 0, unaligned stride/offset, lane 63 past 64 KiB, non-affine sums and products, a lane address read as data, a read with no matching write, a changed payload, a second DS modifier, exact s_sendmsg message 9 only.
  • GPU readback. startup_gfx2hlsl_ngg_passthrough_warp draws a vertex shader that writes twelve payload words to LDS (stride 48, offsets 0..44), reads them back and exports them; the pixels are compared with a CPU reference. The fixture assembles from tests/startup_gfx2hlsl_ngg_passthrough_tail.s.
  • Assumption, stated plainly. The proof covers lanes of one wave. Two waves writing one address with different values would race on hardware as well; separation between waves is the program's own per-wave base, which the instruction stream here cannot prove.
  • Not measured. How many of the 846 census shapes the proof accepts: the census inputs are not available to this run, so no number is claimed.

Verification: the Win2025 dev + release receipt is in the comment above (3/3 passed in both presets for ^startup_gfx2hlsl_ngg_passthrough, plus the Python checks). Locally on Linux: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py and python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py binary <llvm-mc>, plus the startup_gfx2hlsl_* Python checks.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7177552183 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7177552183). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-25T23:25:59Z. --- @R0Y00 @MasterDomino the LDS point is now handled by a proof, not a refusal. Head `d909d5f8`. Your request: prove the four-byte intervals disjoint across all active lanes and write offsets, enforced in the translator, or refuse; add an aliasing control with distinct per-lane payloads and a disjoint case. - **Layout enforced.** The entry `v0` is a packed word, so it is no longer accepted as a lane address. The address must be `stride * lane + offset` built from `v_mbcnt_lo_u32_b32 v, -1, 0` + `v_mbcnt_hi_u32_b32 v, -1, v` (lane 0..63) by `v_mov`, `v_lshlrev`, `v_add_nc`, `v_mul_u32_u24`/`v_mul_lo_u32`, `v_mad_u32_u24` with immediates. Stride and offset must be 4-byte aligned and stay inside 64 KiB for all 64 lanes. - **Disjointness enforced.** Every `ds_write_b32` is checked against every earlier write and itself for all lane pairs (`Stage.lds_overlap`); any meeting is refused with the two strides and offsets named. A read takes the write with the identical form, and is refused if the payload register changed. - **Aliasing control.** Stride 4, offsets 16 and 20, distinct payloads `v2`/`v8`: refused (`not disjoint`). Mutation: with the overlap check replaced by `False` the same program is lowered, so the control fails without the check. - **Disjoint case.** Stride 8, offsets 0 and 4, distinct payloads: lowered to `v3 = v2; v9 = v8;`. Also lowered: stride 12 from a mad with a read through another register of equal form, and stride 4 with one offset. - **Other controls refused:** entry `v0` and a copy of it, `v_mbcnt_lo` alone, stride 0, unaligned stride/offset, lane 63 past 64 KiB, non-affine sums and products, a lane address read as data, a read with no matching write, a changed payload, a second DS modifier, exact `s_sendmsg` message 9 only. - **GPU readback.** `startup_gfx2hlsl_ngg_passthrough_warp` draws a vertex shader that writes twelve payload words to LDS (stride 48, offsets 0..44), reads them back and exports them; the pixels are compared with a CPU reference. The fixture assembles from `tests/startup_gfx2hlsl_ngg_passthrough_tail.s`. - **Assumption, stated plainly.** The proof covers lanes of one wave. Two waves writing one address with different values would race on hardware as well; separation between waves is the program's own per-wave base, which the instruction stream here cannot prove. - **Not measured.** How many of the 846 census shapes the proof accepts: the census inputs are not available to this run, so no number is claimed. Verification: the Win2025 dev + release receipt is in the comment above (3/3 passed in both presets for `^startup_gfx2hlsl_ngg_passthrough`, plus the Python checks). Locally on Linux: `python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py` and `python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py binary <llvm-mc>`, plus the `startup_gfx2hlsl_*` Python checks. AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 04:04:40 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T03:42:45Z.


Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit 1c8f605f5f1a9e3b8702d3e41d5e4307daa8670c:

  • Debug (--preset dev):
    • Build (cmake --build --preset dev --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2): 2.51s (configure 4.08s)
  • Release /O2 (--preset release):
    • Build (cmake --build --preset release --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2): 2.80s (configure 4.16s)
  • Windows Python checks: tests/mesh_heap_sampler_check.py ok (0.9s), tests/startup_buffer_address_check.py ok (0.6s), tests/startup_buffer_format_word3_table_check.py ok (0.1s), tests/startup_compute_request_offline_check.py ok (0.6s), tests/startup_compute_store_format_xyzw_check.py ok (0.3s), tests/startup_compute_translate_check.py ok (0.2s), tests/startup_flat_param_check.py ok (0.2s), tests/startup_gfx2hlsl_add_sub_co_check.py ok (0.1s), tests/startup_gfx2hlsl_add_sub_co_ci_check.py ok (0.2s), tests/startup_gfx2hlsl_bit_alu_check.py ok (0.8s), tests/startup_gfx2hlsl_capture_check.py ok (1.2s), tests/startup_gfx2hlsl_cmp16_check.py ok (0.3s), tests/startup_gfx2hlsl_cmp_class_f16_sdwa_check.py ok (44.1s), tests/startup_gfx2hlsl_compare_dst_check.py ok (0.2s), tests/startup_gfx2hlsl_compute_check.py ok (0.7s), tests/startup_gfx2hlsl_cselect_mask_check.py ok (0.2s), tests/startup_gfx2hlsl_cvt_alu_check.py ok (0.3s), tests/startup_gfx2hlsl_cvt_off_f32_i4_check.py ok (0.4s), tests/startup_gfx2hlsl_cvt_pk_int16_check.py ok (0.5s), tests/startup_gfx2hlsl_f32_lg_check.py ok (2.0s), tests/startup_gfx2hlsl_f32_nan_check.py ok (6.1s), tests/startup_gfx2hlsl_fma_mix_check.py ok (0.1s), tests/startup_gfx2hlsl_getpc_refusal_check.py ok (0.1s), tests/startup_gfx2hlsl_handler_arity_check.py ok (0.1s), tests/startup_gfx2hlsl_heap_record_check.py ok (0.2s), tests/startup_gfx2hlsl_image_arity_check.py ok (0.1s), tests/startup_gfx2hlsl_image_get_lod_check.py ok (0.2s), tests/startup_gfx2hlsl_int_med3_check.py ok (0.1s), tests/startup_gfx2hlsl_interp_p2_hi_check.py ok (0.2s), tests/startup_gfx2hlsl_join_symbols_check.py ok (0.2s), tests/startup_gfx2hlsl_loop_constants_check.py ok (0.1s), tests/startup_gfx2hlsl_mask_data_check.py ok (0.1s), tests/startup_gfx2hlsl_mask_overwrite_check.py ok (0.1s), tests/startup_gfx2hlsl_operand_count_check.py ok (0.5s), tests/startup_gfx2hlsl_pack_absdiff_check.py ok (4.4s), tests/startup_gfx2hlsl_pack_b32_f16_check.py ok (0.3s), tests/startup_gfx2hlsl_readfirstlane_recompute_check.py ok (0.2s), tests/startup_gfx2hlsl_readfirstlane_uniform_check.py ok (0.2s), tests/startup_gfx2hlsl_refusals_check.py ok (0.9s), tests/startup_gfx2hlsl_root_check.py ok (1.0s), tests/startup_gfx2hlsl_s_abs_check.py ok (0.1s), tests/startup_gfx2hlsl_s_bitset_check.py ok (0.2s), tests/startup_gfx2hlsl_s_ff0_check.py ok (0.1s), tests/startup_gfx2hlsl_s_ff1_check.py ok (0.1s), tests/startup_gfx2hlsl_s_flbit_check.py ok (0.1s), tests/startup_gfx2hlsl_s_quadmask_check.py ok (0.1s), tests/startup_gfx2hlsl_sad_check.py ok (0.5s), tests/startup_gfx2hlsl_saveexec_same_reg_check.py ok (0.1s), tests/startup_gfx2hlsl_scalar_arity_check.py ok (0.3s), tests/startup_gfx2hlsl_scalar_brev_fold_check.py ok (0.2s), tests/startup_gfx2hlsl_scalar_m0_check.py ok (0.2s), tests/startup_gfx2hlsl_scalar_null_check.py ok (0.2s), tests/startup_gfx2hlsl_scalar_table_arity_check.py ok (0.4s), tests/startup_gfx2hlsl_sdwa_cndmask_check.py ok (0.3s), tests/startup_gfx2hlsl_sdwa_cvt_check.py ok (0.4s), tests/startup_gfx2hlsl_sgpr_spill_check.py ok (0.2s), tests/startup_gfx2hlsl_shift64_check.py ok (0.3s), tests/startup_gfx2hlsl_sload_const_offset_check.py ok (0.1s), tests/startup_gfx2hlsl_smem_offset_check.py ok (0.1s), tests/startup_gfx2hlsl_sop2_complement_check.py ok (6.2s), tests/startup_gfx2hlsl_sopk_accum_check.py ok (1.2s), tests/startup_gfx2hlsl_sopk_signext_check.py ok (0.1s), tests/startup_gfx2hlsl_spill_branches_check.py ok (1.0s), tests/startup_gfx2hlsl_swap_check.py ok (0.4s), tests/startup_gfx2hlsl_vopc_sdwa_check.py ok (5.2s), tests/startup_gfx2hlsl_waitcnt_depctr_check.py ok (0.1s), tests/startup_gfx2hlsl_watch_check.py ok (2.8s), tests/startup_image_2d_array_check.py ok (0.2s), tests/startup_image_3d_check.py ok (0.2s), tests/startup_image_gather_lz_check.py ok (0.7s), tests/startup_image_load_d16_check.py ok (1.1s), tests/startup_image_sample_a16_check.py ok (0.3s), tests/startup_image_sample_b_check.py ok (0.3s), tests/startup_image_sample_c_check.py ok (0.3s), tests/startup_image_sample_l_check.py ok (0.2s), tests/startup_image_sample_lod_check.py ok (0.7s), tests/startup_inline_sampler_check.py ok (0.2s), tests/startup_mesh57_depth_only_check.py ok (0.2s), tests/startup_mesh57_lane_spill_check.py ok (0.3s), tests/startup_mesh57_loop_check.py ok (0.2s), tests/startup_mesh57_loop_refusal_check.py ok (0.2s), tests/startup_mesh57_skeleton_check.py ok (1.3s), tests/startup_run_ps1_check.py ok (19.2s), tests/startup_run_sh_check.py skipped (0.1s), tests/startup_sampler_heap_check.py ok (0.3s), tests/startup_shader_cache_rekey_check.py ok (4.6s), tests/startup_smem_address_check.py ok (0.3s), tests/startup_stream_fetch_check.py ok (0.4s), tests/startup_stream_interface_check.py ok (0.4s), tests/startup_translator_check.py ok (0.8s)
  • sccache: 7/23 hits; wall 147.7s

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7181957507 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7181957507). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T03:42:45Z. --- Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit `1c8f605f5f1a9e3b8702d3e41d5e4307daa8670c`: - **Debug (`--preset dev`)**: - Build (`cmake --build --preset dev --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2`): `2.51s` (configure `4.08s`) - **Release `/O2` (`--preset release`)**: - Build (`cmake --build --preset release --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2`): `2.80s` (configure `4.16s`) - **Windows Python checks**: `tests/mesh_heap_sampler_check.py` ok (`0.9s`), `tests/startup_buffer_address_check.py` ok (`0.6s`), `tests/startup_buffer_format_word3_table_check.py` ok (`0.1s`), `tests/startup_compute_request_offline_check.py` ok (`0.6s`), `tests/startup_compute_store_format_xyzw_check.py` ok (`0.3s`), `tests/startup_compute_translate_check.py` ok (`0.2s`), `tests/startup_flat_param_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_add_sub_co_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_add_sub_co_ci_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_bit_alu_check.py` ok (`0.8s`), `tests/startup_gfx2hlsl_capture_check.py` ok (`1.2s`), `tests/startup_gfx2hlsl_cmp16_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_cmp_class_f16_sdwa_check.py` ok (`44.1s`), `tests/startup_gfx2hlsl_compare_dst_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_compute_check.py` ok (`0.7s`), `tests/startup_gfx2hlsl_cselect_mask_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_cvt_alu_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_cvt_off_f32_i4_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_cvt_pk_int16_check.py` ok (`0.5s`), `tests/startup_gfx2hlsl_f32_lg_check.py` ok (`2.0s`), `tests/startup_gfx2hlsl_f32_nan_check.py` ok (`6.1s`), `tests/startup_gfx2hlsl_fma_mix_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_getpc_refusal_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_handler_arity_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_heap_record_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_image_arity_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_image_get_lod_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_int_med3_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_interp_p2_hi_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_join_symbols_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_loop_constants_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_mask_data_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_mask_overwrite_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_operand_count_check.py` ok (`0.5s`), `tests/startup_gfx2hlsl_pack_absdiff_check.py` ok (`4.4s`), `tests/startup_gfx2hlsl_pack_b32_f16_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_readfirstlane_recompute_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_readfirstlane_uniform_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_refusals_check.py` ok (`0.9s`), `tests/startup_gfx2hlsl_root_check.py` ok (`1.0s`), `tests/startup_gfx2hlsl_s_abs_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_bitset_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_s_ff0_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_ff1_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_flbit_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_quadmask_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_sad_check.py` ok (`0.5s`), `tests/startup_gfx2hlsl_saveexec_same_reg_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_scalar_arity_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_scalar_brev_fold_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_scalar_m0_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_scalar_null_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_scalar_table_arity_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_sdwa_cndmask_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_sdwa_cvt_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_sgpr_spill_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_shift64_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_sload_const_offset_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_smem_offset_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_sop2_complement_check.py` ok (`6.2s`), `tests/startup_gfx2hlsl_sopk_accum_check.py` ok (`1.2s`), `tests/startup_gfx2hlsl_sopk_signext_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_spill_branches_check.py` ok (`1.0s`), `tests/startup_gfx2hlsl_swap_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_vopc_sdwa_check.py` ok (`5.2s`), `tests/startup_gfx2hlsl_waitcnt_depctr_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_watch_check.py` ok (`2.8s`), `tests/startup_image_2d_array_check.py` ok (`0.2s`), `tests/startup_image_3d_check.py` ok (`0.2s`), `tests/startup_image_gather_lz_check.py` ok (`0.7s`), `tests/startup_image_load_d16_check.py` ok (`1.1s`), `tests/startup_image_sample_a16_check.py` ok (`0.3s`), `tests/startup_image_sample_b_check.py` ok (`0.3s`), `tests/startup_image_sample_c_check.py` ok (`0.3s`), `tests/startup_image_sample_l_check.py` ok (`0.2s`), `tests/startup_image_sample_lod_check.py` ok (`0.7s`), `tests/startup_inline_sampler_check.py` ok (`0.2s`), `tests/startup_mesh57_depth_only_check.py` ok (`0.2s`), `tests/startup_mesh57_lane_spill_check.py` ok (`0.3s`), `tests/startup_mesh57_loop_check.py` ok (`0.2s`), `tests/startup_mesh57_loop_refusal_check.py` ok (`0.2s`), `tests/startup_mesh57_skeleton_check.py` ok (`1.3s`), `tests/startup_run_ps1_check.py` ok (`19.2s`), `tests/startup_run_sh_check.py` skipped (`0.1s`), `tests/startup_sampler_heap_check.py` ok (`0.3s`), `tests/startup_shader_cache_rekey_check.py` ok (`4.6s`), `tests/startup_smem_address_check.py` ok (`0.3s`), `tests/startup_stream_fetch_check.py` ok (`0.4s`), `tests/startup_stream_interface_check.py` ok (`0.4s`), `tests/startup_translator_check.py` ok (`0.8s`) - `sccache`: 7/23 hits; wall `147.7s` AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 04:04:40 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T03:42:46Z.


Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit 1c8f605f5f1a9e3b8702d3e41d5e4307daa8670c:

  • Debug (--preset dev):
    • Build (cmake --build --preset dev --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2): 1.87s (configure 0.00s)
    • Test (ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.80s: startup_gfx2hlsl_ngg_passthrough_warp 1.42s, startup_gfx2hlsl_ngg_passthrough_hardware 1.43s, startup_gfx2hlsl_ngg_passthrough 0.13s)
  • Release /O2 (--preset release):
    • Build (cmake --build --preset release --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2): 1.96s (configure 0.00s)
    • Test (ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.83s: startup_gfx2hlsl_ngg_passthrough_warp 1.38s, startup_gfx2hlsl_ngg_passthrough_hardware 1.39s, startup_gfx2hlsl_ngg_passthrough 0.17s)
  • Windows Python checks: tests/startup_gfx2hlsl_ngg_passthrough_check.py ok (0.2s)
  • sccache: 4/4 hits; wall 21.8s

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7181957670 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7181957670). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T03:42:46Z. --- Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit `1c8f605f5f1a9e3b8702d3e41d5e4307daa8670c`: - **Debug (`--preset dev`)**: - Build (`cmake --build --preset dev --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2`): `1.87s` (configure `0.00s`) - Test (`ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.80s`: `startup_gfx2hlsl_ngg_passthrough_warp` `1.42s`, `startup_gfx2hlsl_ngg_passthrough_hardware` `1.43s`, `startup_gfx2hlsl_ngg_passthrough` `0.13s`) - **Release `/O2` (`--preset release`)**: - Build (`cmake --build --preset release --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2`): `1.96s` (configure `0.00s`) - Test (`ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.83s`: `startup_gfx2hlsl_ngg_passthrough_warp` `1.38s`, `startup_gfx2hlsl_ngg_passthrough_hardware` `1.39s`, `startup_gfx2hlsl_ngg_passthrough` `0.17s`) - **Windows Python checks**: `tests/startup_gfx2hlsl_ngg_passthrough_check.py` ok (`0.2s`) - `sccache`: 4/4 hits; wall `21.8s` AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 04:04:40 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T03:42:56Z.


@R0Y00 @MasterDomino head 1c8f605f is ready for another look. The LDS point from the 12:25Z review is handled by a proof, as described in the previous reply (d909d5f8). Since then:

  • Merged origin/main (107 commits). One conflict in tools/startup/gfx2hlsl.py, resolved by keeping both sides. No force-push.
  • The assembly check now runs in CI. startup_gfx2hlsl_ngg_passthrough_check.py binary llvm-mc-15 is in the pixel-binary job, so the hand-written tail words in the WARP fixture are checked against the assembler on every push.
  • Wording made exact. The proof covers the lanes of one wave. Separation between waves is not analysed. The comment in gfx2hlsl.py and the paragraph in docs/experiments.md now say that, instead of pointing to a per-wave base the translator does not check.
  • Still true from the earlier reply: aliasing control (stride 4, offsets 16 and 20, distinct payloads) is refused; removing the overlap check lowers it, so the control fails. The stride 8 / offsets 0 and 4 case is lowered. The WARP draw reads twelve LDS-forwarded words back and compares them with a CPU reference.
  • Not measured: how many of the 846 census shapes the proof accepts. The census inputs are not available here, so no number is claimed.

Verification:

  • CI on 1c8f605f: Linux Python checks, gfx1013 assemble and translate, Windows build and test all green.
  • Win2025 (D3D12 WARP), dev and release: ^startup_gfx2hlsl_ngg_passthrough 3/3 passed in both presets, plus the full default plan (receipts in the two comments above). One first full run failed only in tests/startup_run_ps1_check.py (PowerShell launcher, unrelated to this change); the re-run passed.
  • Linux: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py, the same with binary llvm-mc-19, python3 -B tests/docs_links_check.py, and every tests/startup_gfx2hlsl_*_check.py that runs without a GPU.

Re-requesting review.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7181960304 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7181960304). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T03:42:56Z. --- @R0Y00 @MasterDomino head `1c8f605f` is ready for another look. The LDS point from the 12:25Z review is handled by a proof, as described in the previous reply (`d909d5f8`). Since then: - **Merged `origin/main`** (107 commits). One conflict in `tools/startup/gfx2hlsl.py`, resolved by keeping both sides. No force-push. - **The assembly check now runs in CI.** `startup_gfx2hlsl_ngg_passthrough_check.py binary llvm-mc-15` is in the `pixel-binary` job, so the hand-written tail words in the WARP fixture are checked against the assembler on every push. - **Wording made exact.** The proof covers the lanes of one wave. Separation between waves is not analysed. The comment in `gfx2hlsl.py` and the paragraph in `docs/experiments.md` now say that, instead of pointing to a per-wave base the translator does not check. - **Still true from the earlier reply:** aliasing control (stride 4, offsets 16 and 20, distinct payloads) is refused; removing the overlap check lowers it, so the control fails. The stride 8 / offsets 0 and 4 case is lowered. The WARP draw reads twelve LDS-forwarded words back and compares them with a CPU reference. - **Not measured:** how many of the 846 census shapes the proof accepts. The census inputs are not available here, so no number is claimed. Verification: - CI on `1c8f605f`: Linux Python checks, gfx1013 assemble and translate, Windows build and test all green. - Win2025 (D3D12 WARP), dev and release: `^startup_gfx2hlsl_ngg_passthrough` 3/3 passed in both presets, plus the full default plan (receipts in the two comments above). One first full run failed only in `tests/startup_run_ps1_check.py` (PowerShell launcher, unrelated to this change); the re-run passed. - Linux: `python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py`, the same with `binary llvm-mc-19`, `python3 -B tests/docs_links_check.py`, and every `tests/startup_gfx2hlsl_*_check.py` that runs without a GPU. Re-requesting review. AI-assisted; commands listed were executed locally.
MasterDomino commented 2026-11-26 08:01:40 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by MasterDomino on 2026-11-26T07:35:29Z.

Review: COMMENTED


Reviewed 1c8f605f (comment only; @R0Y00's change request is his to clear).

On the change request (12:25Z):

  1. Addresses: the entry v0 and its copies are no longer accepted as addresses. Addresses must be stride * lane + offset built from v_mbcnt_lo / v_mbcnt_hi, aligned, and inside 64 KiB.
  2. Overlap: lds_overlap checks every lane pair of each write against every earlier write, and against itself. Removing the check against earlier writes makes the 16/20 aliasing control lower to v3 = v8; v9 = v2, so the control catches it.
  3. For @R0Y00 to decide: the proof covers one wave. Any per-wave SGPR base is refused, so every accepted address is the same in all waves of an NGG group that shares LDS. In a multi-wave group, the "own value" result would then not be a possible guest outcome. tedin7 states this limit; whether "all active lanes" was meant to cover the whole LDS-sharing group is your call.

Requested before merge:

  1. Rebase: please rebase onto current main. tools/startup/gfx2hlsl.py conflicts at set_v, where main added align4=False.
  2. Two missing controls: two refusals have no control. Removing either guard leaves every check green and lowers the round trip to v3 = v2. Please add both as refused fixtures:
    • v_mbcnt_hi_u32_b32 v1, -1, 0 without the lo result, which gives 0 in lanes 0..31;
    • a negative offset (v_add_nc_u32 v11, -8, v10), which puts lane 0 outside LDS.
  3. Description:
    • "846 of 1,171 pairs can now be translated" isn't measured, as your later comment says.
    • The WARP draw checks register forwarding, since its payloads are the same in every lane and it bypasses LDS. It doesn't check cross-lane behaviour; the static proof covers that, and the text should say so.

No cache bump is needed. Every new path was refused at the merge base (s_sendmsg, v_mbcnt in a VS, and VS LDS ops). The 504 pipelines that the no-argument startup_* checks translate have identical HLSL before and after.

Runs: Windows 11 build 26300; RX 9070 XT (driver 32.0.32029.2010); WARP 10.0.26100.9818.

  • ctest --preset dev --no-tests=error -R 'startup_gfx2hlsl|startup_ngg|startup_mesh57': 272 passed out of 273, including the three startup_gfx2hlsl_ngg_passthrough tests and startup_ngg_slice. The one failure, startup_gfx2hlsl_fma_mix_dispatch_hardware, also fails on main (#2746).
  • startup_gfx2hlsl_ngg_passthrough_check.py binary matches llvm-mc 15.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:review:6070123540 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#pullrequestreview-6070123540). Originally posted by [MasterDomino](https://github.com/MasterDomino) on 2026-11-26T07:35:29Z. **Review:** COMMENTED --- Reviewed `1c8f605f` (comment only; @R0Y00's change request is his to clear). **On the change request** (12:25Z): 1. **Addresses:** the entry `v0` and its copies are no longer accepted as addresses. Addresses must be `stride * lane + offset` built from `v_mbcnt_lo` / `v_mbcnt_hi`, aligned, and inside 64 KiB. 2. **Overlap:** `lds_overlap` checks every lane pair of each write against every earlier write, and against itself. Removing the check against earlier writes makes the 16/20 aliasing control lower to `v3 = v8; v9 = v2`, so the control catches it. 3. **For @R0Y00 to decide:** the proof covers one wave. Any per-wave SGPR base is refused, so every accepted address is the same in all waves of an NGG group that shares LDS. In a multi-wave group, the "own value" result would then not be a possible guest outcome. tedin7 states this limit; whether "all active lanes" was meant to cover the whole LDS-sharing group is your call. **Requested before merge:** 1. **Rebase:** please rebase onto current `main`. `tools/startup/gfx2hlsl.py` conflicts at `set_v`, where `main` added `align4=False`. 2. **Two missing controls:** two refusals have no control. Removing either guard leaves every check green and lowers the round trip to `v3 = v2`. Please add both as refused fixtures: - `v_mbcnt_hi_u32_b32 v1, -1, 0` without the `lo` result, which gives 0 in lanes 0..31; - a negative offset (`v_add_nc_u32 v11, -8, v10`), which puts lane 0 outside LDS. 3. **Description:** - "846 of 1,171 pairs can now be translated" isn't measured, as your later comment says. - The WARP draw checks register forwarding, since its payloads are the same in every lane and it bypasses LDS. It doesn't check cross-lane behaviour; the static proof covers that, and the text should say so. **No cache bump is needed.** Every new path was refused at the merge base (`s_sendmsg`, `v_mbcnt` in a VS, and VS LDS ops). The 504 pipelines that the no-argument `startup_*` checks translate have identical HLSL before and after. **Runs:** Windows 11 build 26300; RX 9070 XT (driver 32.0.32029.2010); WARP 10.0.26100.9818. - `ctest --preset dev --no-tests=error -R 'startup_gfx2hlsl|startup_ngg|startup_mesh57'`: 272 passed out of 273, including the three `startup_gfx2hlsl_ngg_passthrough` tests and `startup_ngg_slice`. The one failure, `startup_gfx2hlsl_fma_mix_dispatch_hardware`, also fails on `main` (#2746). - `startup_gfx2hlsl_ngg_passthrough_check.py binary` matches llvm-mc 15. AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 08:01:57 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T07:46:54Z.


Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit 106c044513f1aa35797dd97a90c674d2e43ead9b:

  • Debug (--preset dev):
    • Build (cmake --build --preset dev --target offscreen_check -- -j 2): 62.13s (configure 1.89s)
    • Test (ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.17s: startup_gfx2hlsl_ngg_passthrough_hardware 0.92s, startup_gfx2hlsl_ngg_passthrough_warp 0.93s, startup_gfx2hlsl_ngg_passthrough 0.11s)
  • Release /O2 (--preset release):
    • Build (cmake --build --preset release --target offscreen_check -- -j 2): 90.06s (configure 2.17s)
    • Test (ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.17s: startup_gfx2hlsl_ngg_passthrough_warp 0.91s, startup_gfx2hlsl_ngg_passthrough_hardware 0.92s, startup_gfx2hlsl_ngg_passthrough 0.10s)
  • Windows Python checks: tests/mesh_heap_sampler_check.py ok (0.8s), tests/startup_buffer_address_check.py ok (0.5s), tests/startup_buffer_format_word3_table_check.py ok (0.1s), tests/startup_compute_global_load_check.py ok (0.2s), tests/startup_compute_request_offline_check.py ok (0.7s), tests/startup_compute_store_format_xyzw_check.py ok (0.3s), tests/startup_compute_translate_check.py ok (0.3s), tests/startup_flat_param_check.py ok (0.2s), tests/startup_gfx2hlsl_add_sub_co_check.py ok (0.1s), tests/startup_gfx2hlsl_add_sub_co_ci_check.py ok (0.2s), tests/startup_gfx2hlsl_bfm_b64_check.py ok (1.5s), tests/startup_gfx2hlsl_bit_alu_check.py ok (0.8s), tests/startup_gfx2hlsl_capture_check.py ok (1.4s), tests/startup_gfx2hlsl_cmp16_check.py ok (0.3s), tests/startup_gfx2hlsl_cmp_class_f16_sdwa_check.py ok (45.5s), tests/startup_gfx2hlsl_compare_dst_check.py ok (0.1s), tests/startup_gfx2hlsl_compute_check.py ok (0.6s), tests/startup_gfx2hlsl_const_copy_join_check.py ok (0.1s), tests/startup_gfx2hlsl_cselect_mask_check.py ok (0.1s), tests/startup_gfx2hlsl_cvt_alu_check.py ok (0.2s), tests/startup_gfx2hlsl_cvt_off_f32_i4_check.py ok (0.4s), tests/startup_gfx2hlsl_cvt_pk_int16_check.py ok (0.4s), tests/startup_gfx2hlsl_f32_lg_check.py ok (1.3s), tests/startup_gfx2hlsl_f32_nan_check.py ok (5.0s), tests/startup_gfx2hlsl_fma_mix_check.py ok (0.1s), tests/startup_gfx2hlsl_getpc_refusal_check.py ok (0.1s), tests/startup_gfx2hlsl_handler_arity_check.py ok (0.1s), tests/startup_gfx2hlsl_heap_record_check.py ok (0.2s), tests/startup_gfx2hlsl_heap_word_check.py ok (0.2s), tests/startup_gfx2hlsl_image_arity_check.py ok (0.1s), tests/startup_gfx2hlsl_image_get_lod_check.py ok (0.2s), tests/startup_gfx2hlsl_int_med3_check.py ok (0.1s), tests/startup_gfx2hlsl_interp_p2_hi_check.py ok (0.3s), tests/startup_gfx2hlsl_join_symbols_check.py ok (0.3s), tests/startup_gfx2hlsl_loop_constants_check.py ok (0.1s), tests/startup_gfx2hlsl_mask_data_check.py ok (0.1s), tests/startup_gfx2hlsl_mask_overwrite_check.py ok (0.1s), tests/startup_gfx2hlsl_operand_count_check.py ok (0.4s), tests/startup_gfx2hlsl_pack_absdiff_check.py ok (2.5s), tests/startup_gfx2hlsl_pack_b32_f16_check.py ok (0.2s), tests/startup_gfx2hlsl_readfirstlane_load_recompute_check.py ok (0.1s), tests/startup_gfx2hlsl_readfirstlane_recompute_check.py ok (0.1s), tests/startup_gfx2hlsl_readfirstlane_uniform_check.py ok (0.1s), tests/startup_gfx2hlsl_refusals_check.py ok (0.6s), tests/startup_gfx2hlsl_root_check.py ok (0.9s), tests/startup_gfx2hlsl_s_abs_check.py ok (0.1s), tests/startup_gfx2hlsl_s_bitset_check.py ok (0.1s), tests/startup_gfx2hlsl_s_ff0_check.py ok (0.1s), tests/startup_gfx2hlsl_s_ff1_check.py ok (0.1s), tests/startup_gfx2hlsl_s_flbit_check.py ok (0.1s), tests/startup_gfx2hlsl_s_quadmask_b64_check.py ok (0.1s), tests/startup_gfx2hlsl_s_quadmask_check.py ok (0.1s), tests/startup_gfx2hlsl_sad_check.py ok (0.3s), tests/startup_gfx2hlsl_sad_hi_msad_check.py ok (0.3s), tests/startup_gfx2hlsl_saveexec_same_reg_check.py ok (0.1s), tests/startup_gfx2hlsl_scalar_arity_check.py ok (0.3s), tests/startup_gfx2hlsl_scalar_brev_fold_check.py ok (0.2s), tests/startup_gfx2hlsl_scalar_m0_check.py ok (0.2s), tests/startup_gfx2hlsl_scalar_null_check.py ok (0.2s), tests/startup_gfx2hlsl_scalar_table_arity_check.py ok (0.4s), tests/startup_gfx2hlsl_sdwa_cndmask_check.py ok (0.2s), tests/startup_gfx2hlsl_sdwa_cvt_check.py ok (0.3s), tests/startup_gfx2hlsl_sgpr_spill_check.py ok (0.2s), tests/startup_gfx2hlsl_shift64_check.py ok (0.2s), tests/startup_gfx2hlsl_sload_const_offset_check.py ok (0.1s), tests/startup_gfx2hlsl_smem_offset_check.py ok (0.1s), tests/startup_gfx2hlsl_sop2_complement_check.py ok (5.9s), tests/startup_gfx2hlsl_sopk_accum_check.py ok (1.2s), tests/startup_gfx2hlsl_sopk_signext_check.py ok (0.1s), tests/startup_gfx2hlsl_spill_branches_check.py ok (1.1s), tests/startup_gfx2hlsl_swap_check.py ok (0.4s), tests/startup_gfx2hlsl_vopc_sdwa_check.py ok (4.5s), tests/startup_gfx2hlsl_waitcnt_depctr_check.py ok (0.1s), tests/startup_gfx2hlsl_watch_check.py ok (2.6s), tests/startup_image_2d_array_check.py ok (0.2s), tests/startup_image_3d_check.py ok (0.2s), tests/startup_image_gather_lz_check.py ok (0.6s), tests/startup_image_load_d16_check.py ok (1.0s), tests/startup_image_sample_a16_check.py ok (0.3s), tests/startup_image_sample_b_check.py ok (0.3s), tests/startup_image_sample_c_check.py ok (0.2s), tests/startup_image_sample_l_check.py ok (0.2s), tests/startup_image_sample_lod_check.py ok (0.7s), tests/startup_inline_sampler_check.py ok (0.2s), tests/startup_mesh57_depth_only_check.py ok (0.2s), tests/startup_mesh57_lane_spill_check.py ok (0.2s), tests/startup_mesh57_loop_check.py ok (0.2s), tests/startup_mesh57_loop_refusal_check.py ok (0.2s), tests/startup_mesh57_skeleton_check.py ok (1.2s), tests/startup_run_ps1_check.py ok (10.8s), tests/startup_run_sh_check.py skipped (0.1s), tests/startup_sampler_heap_check.py ok (0.1s), tests/startup_shader_cache_rekey_check.py ok (2.2s), tests/startup_smem_address_check.py ok (0.1s), tests/startup_stream_fetch_check.py ok (0.2s), tests/startup_stream_interface_check.py ok (0.2s), tests/startup_translator_check.py ok (0.4s)
  • sccache: 3/122 hits; wall 273.2s

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7185827467 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7185827467). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T07:46:54Z. --- Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit `106c044513f1aa35797dd97a90c674d2e43ead9b`: - **Debug (`--preset dev`)**: - Build (`cmake --build --preset dev --target offscreen_check -- -j 2`): `62.13s` (configure `1.89s`) - Test (`ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.17s`: `startup_gfx2hlsl_ngg_passthrough_hardware` `0.92s`, `startup_gfx2hlsl_ngg_passthrough_warp` `0.93s`, `startup_gfx2hlsl_ngg_passthrough` `0.11s`) - **Release `/O2` (`--preset release`)**: - Build (`cmake --build --preset release --target offscreen_check -- -j 2`): `90.06s` (configure `2.17s`) - Test (`ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.17s`: `startup_gfx2hlsl_ngg_passthrough_warp` `0.91s`, `startup_gfx2hlsl_ngg_passthrough_hardware` `0.92s`, `startup_gfx2hlsl_ngg_passthrough` `0.10s`) - **Windows Python checks**: `tests/mesh_heap_sampler_check.py` ok (`0.8s`), `tests/startup_buffer_address_check.py` ok (`0.5s`), `tests/startup_buffer_format_word3_table_check.py` ok (`0.1s`), `tests/startup_compute_global_load_check.py` ok (`0.2s`), `tests/startup_compute_request_offline_check.py` ok (`0.7s`), `tests/startup_compute_store_format_xyzw_check.py` ok (`0.3s`), `tests/startup_compute_translate_check.py` ok (`0.3s`), `tests/startup_flat_param_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_add_sub_co_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_add_sub_co_ci_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_bfm_b64_check.py` ok (`1.5s`), `tests/startup_gfx2hlsl_bit_alu_check.py` ok (`0.8s`), `tests/startup_gfx2hlsl_capture_check.py` ok (`1.4s`), `tests/startup_gfx2hlsl_cmp16_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_cmp_class_f16_sdwa_check.py` ok (`45.5s`), `tests/startup_gfx2hlsl_compare_dst_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_compute_check.py` ok (`0.6s`), `tests/startup_gfx2hlsl_const_copy_join_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_cselect_mask_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_cvt_alu_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_cvt_off_f32_i4_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_cvt_pk_int16_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_f32_lg_check.py` ok (`1.3s`), `tests/startup_gfx2hlsl_f32_nan_check.py` ok (`5.0s`), `tests/startup_gfx2hlsl_fma_mix_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_getpc_refusal_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_handler_arity_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_heap_record_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_heap_word_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_image_arity_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_image_get_lod_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_int_med3_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_interp_p2_hi_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_join_symbols_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_loop_constants_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_mask_data_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_mask_overwrite_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_operand_count_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_pack_absdiff_check.py` ok (`2.5s`), `tests/startup_gfx2hlsl_pack_b32_f16_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_readfirstlane_load_recompute_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_readfirstlane_recompute_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_readfirstlane_uniform_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_refusals_check.py` ok (`0.6s`), `tests/startup_gfx2hlsl_root_check.py` ok (`0.9s`), `tests/startup_gfx2hlsl_s_abs_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_bitset_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_ff0_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_ff1_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_flbit_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_quadmask_b64_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_s_quadmask_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_sad_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_sad_hi_msad_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_saveexec_same_reg_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_scalar_arity_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_scalar_brev_fold_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_scalar_m0_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_scalar_null_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_scalar_table_arity_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_sdwa_cndmask_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_sdwa_cvt_check.py` ok (`0.3s`), `tests/startup_gfx2hlsl_sgpr_spill_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_shift64_check.py` ok (`0.2s`), `tests/startup_gfx2hlsl_sload_const_offset_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_smem_offset_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_sop2_complement_check.py` ok (`5.9s`), `tests/startup_gfx2hlsl_sopk_accum_check.py` ok (`1.2s`), `tests/startup_gfx2hlsl_sopk_signext_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_spill_branches_check.py` ok (`1.1s`), `tests/startup_gfx2hlsl_swap_check.py` ok (`0.4s`), `tests/startup_gfx2hlsl_vopc_sdwa_check.py` ok (`4.5s`), `tests/startup_gfx2hlsl_waitcnt_depctr_check.py` ok (`0.1s`), `tests/startup_gfx2hlsl_watch_check.py` ok (`2.6s`), `tests/startup_image_2d_array_check.py` ok (`0.2s`), `tests/startup_image_3d_check.py` ok (`0.2s`), `tests/startup_image_gather_lz_check.py` ok (`0.6s`), `tests/startup_image_load_d16_check.py` ok (`1.0s`), `tests/startup_image_sample_a16_check.py` ok (`0.3s`), `tests/startup_image_sample_b_check.py` ok (`0.3s`), `tests/startup_image_sample_c_check.py` ok (`0.2s`), `tests/startup_image_sample_l_check.py` ok (`0.2s`), `tests/startup_image_sample_lod_check.py` ok (`0.7s`), `tests/startup_inline_sampler_check.py` ok (`0.2s`), `tests/startup_mesh57_depth_only_check.py` ok (`0.2s`), `tests/startup_mesh57_lane_spill_check.py` ok (`0.2s`), `tests/startup_mesh57_loop_check.py` ok (`0.2s`), `tests/startup_mesh57_loop_refusal_check.py` ok (`0.2s`), `tests/startup_mesh57_skeleton_check.py` ok (`1.2s`), `tests/startup_run_ps1_check.py` ok (`10.8s`), `tests/startup_run_sh_check.py` skipped (`0.1s`), `tests/startup_sampler_heap_check.py` ok (`0.1s`), `tests/startup_shader_cache_rekey_check.py` ok (`2.2s`), `tests/startup_smem_address_check.py` ok (`0.1s`), `tests/startup_stream_fetch_check.py` ok (`0.2s`), `tests/startup_stream_interface_check.py` ok (`0.2s`), `tests/startup_translator_check.py` ok (`0.4s`) - `sccache`: 3/122 hits; wall `273.2s` AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 08:01:57 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T07:46:59Z.


@R0Y00 @MasterDomino head 106c0445 (merge of current origin/main, no force-push). Your 12:25Z request (cross-lane byte-range proof) is answered point by point:

  • Proof, enforced in the translator. The LDS address must be stride * lane + offset, built from v_mbcnt_lo/hi with proven ops; stride and offset 4-byte aligned, inside 64 KiB for all 64 lanes. Every ds_write_b32 is checked against every earlier write and itself for all lane pairs (Stage.lds_overlap). Anything unproven is refused with a message naming the missing proof.
  • Aliasing control. Stride 4, offsets 16 and 20, distinct per-lane payloads: refused. A mutation that removes the overlap check lowers it, so the control fails.
  • Disjoint case. Stride 8, offsets 0 and 4: lowered. The WARP draw reads twelve forwarded words back and compares them with a CPU reference.
  • This update. One merge conflict in tools/startup/gfx2hlsl.py (set_v), resolved by keeping both sides: main's align4 argument and this PR's lane-read refusal. The NGG check passes after the merge.
  • Not measured: how many of the 846 census shapes the proof accepts. No number is claimed.

Verification:

  • CI on 106c0445: Linux Python checks, gfx1013 assemble and translate, Windows build and test all green.
  • Win2025 (D3D12 WARP), dev and release: ^startup_gfx2hlsl_ngg_passthrough 3/3 passed in both presets (receipt comment above).
  • Linux: python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py (all ok), every non-GPU tests/startup_gfx2hlsl_*_check.py.
  • Real-GPU run is in the background; I will add one line here when it finishes.

Re-requesting review.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7185829354 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7185829354). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T07:46:59Z. --- @R0Y00 @MasterDomino head `106c0445` (merge of current `origin/main`, no force-push). Your 12:25Z request (cross-lane byte-range proof) is answered point by point: - **Proof, enforced in the translator.** The LDS address must be `stride * lane + offset`, built from `v_mbcnt_lo/hi` with proven ops; stride and offset 4-byte aligned, inside 64 KiB for all 64 lanes. Every `ds_write_b32` is checked against every earlier write and itself for all lane pairs (`Stage.lds_overlap`). Anything unproven is refused with a message naming the missing proof. - **Aliasing control.** Stride 4, offsets 16 and 20, distinct per-lane payloads: refused. A mutation that removes the overlap check lowers it, so the control fails. - **Disjoint case.** Stride 8, offsets 0 and 4: lowered. The WARP draw reads twelve forwarded words back and compares them with a CPU reference. - **This update.** One merge conflict in `tools/startup/gfx2hlsl.py` (`set_v`), resolved by keeping both sides: main's `align4` argument and this PR's lane-read refusal. The NGG check passes after the merge. - **Not measured:** how many of the 846 census shapes the proof accepts. No number is claimed. Verification: - CI on `106c0445`: Linux Python checks, gfx1013 assemble and translate, Windows build and test all green. - Win2025 (D3D12 WARP), dev and release: `^startup_gfx2hlsl_ngg_passthrough` 3/3 passed in both presets (receipt comment above). - Linux: `python3 -B tests/startup_gfx2hlsl_ngg_passthrough_check.py` (all ok), every non-GPU `tests/startup_gfx2hlsl_*_check.py`. - Real-GPU run is in the background; I will add one line here when it finishes. Re-requesting review. AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 09:04:55 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T08:58:41Z.


Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit 27f400935dfc359e64150796ca8fe47d42eb80cc:

  • Debug (--preset dev):
    • Build (cmake --build --preset dev --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2): 38.63s (configure 2.70s)
    • Test (ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.54s: startup_gfx2hlsl_ngg_passthrough_warp 1.24s, startup_gfx2hlsl_ngg_passthrough_hardware 1.26s, startup_gfx2hlsl_ngg_passthrough 0.14s)
  • Release /O2 (--preset release):
    • Build (cmake --build --preset release --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2): 72.29s (configure 2.89s)
    • Test (ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure): 3/3 passed (1.03s: startup_gfx2hlsl_ngg_passthrough_warp 0.81s, startup_gfx2hlsl_ngg_passthrough_hardware 0.83s, startup_gfx2hlsl_ngg_passthrough 0.09s)
  • Windows Python checks: tests/startup_gfx2hlsl_ngg_passthrough_check.py ok (0.1s)
  • sccache: 14/22 hits; wall 125.5s

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7187255771 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7187255771). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T08:58:41Z. --- Verified on Windows Server 2025 (Build 26100, MSVC 14.44.35207 + D3D12 WARP) at commit `27f400935dfc359e64150796ca8fe47d42eb80cc`: - **Debug (`--preset dev`)**: - Build (`cmake --build --preset dev --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2`): `38.63s` (configure `2.70s`) - Test (`ctest --preset dev -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.54s`: `startup_gfx2hlsl_ngg_passthrough_warp` `1.24s`, `startup_gfx2hlsl_ngg_passthrough_hardware` `1.26s`, `startup_gfx2hlsl_ngg_passthrough` `0.14s`) - **Release `/O2` (`--preset release`)**: - Build (`cmake --build --preset release --target d3d12_xs_device_obj d3d12_xs_shim startup_buffer_format_word3_check -- -j 2`): `72.29s` (configure `2.89s`) - Test (`ctest --preset release -R '^startup_gfx2hlsl_ngg_passthrough' --parallel 2 --no-tests=error --output-on-failure`): **3/3 passed** (`1.03s`: `startup_gfx2hlsl_ngg_passthrough_warp` `0.81s`, `startup_gfx2hlsl_ngg_passthrough_hardware` `0.83s`, `startup_gfx2hlsl_ngg_passthrough` `0.09s`) - **Windows Python checks**: `tests/startup_gfx2hlsl_ngg_passthrough_check.py` ok (`0.1s`) - `sccache`: 14/22 hits; wall `125.5s` AI-assisted; commands listed were executed locally.
tedin7 commented 2026-11-26 09:04:55 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T08:58:42Z.


New head 27f40093: merged main (conflict in gfx2hlsl.py lower/_lower resolved, both sides kept), CI green, Win2025 dev and release 3/3 by name (startup_gfx2hlsl_ngg_passthrough, _warp, _hardware). Body now has the Source line. @R0Y00 @MasterDomino ready for another look.

AI-assisted; commands listed were executed locally.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7187256112 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7187256112). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T08:58:42Z. --- New head 27f40093: merged main (conflict in gfx2hlsl.py lower/_lower resolved, both sides kept), CI green, Win2025 dev and release 3/3 by name (startup_gfx2hlsl_ngg_passthrough, _warp, _hardware). Body now has the Source line. @R0Y00 @MasterDomino ready for another look. AI-assisted; commands listed were executed locally.
upstream-sync closed this pull request 2026-11-26 11:02:41 +00:00
tedin7 commented 2026-11-26 11:02:58 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by tedin7 on 2026-11-26T10:12:24Z.


Withdrawn: shader translation is moving to the native C++ frontend (see #870), so we are not continuing this change to the Python translator. The branch stays available if any part is useful later. Thank you to everyone who reviewed and tested it.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:comment:7189050875 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/2096#issuecomment-7189050875). Originally posted by [tedin7](https://github.com/tedin7) on 2026-11-26T10:12:24Z. --- Withdrawn: shader translation is moving to the native C++ frontend (see #870), so we are not continuing this change to the Python translator. The branch stays available if any part is useful later. Thank you to everyone who reviewed and tested it.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
R0Y00/Xbox2Windows!2089
No description provided.