direct compute: accept s_mov_b32 exec_hi in wave32 #3181

Closed
opened 2026-11-27 20:32:12 +00:00 by Leyukaka · 0 comments
Leyukaka commented 2026-11-27 20:32:12 +00:00 (Migrated from github.com)
Contributor

Imported from R0Y00/Xbox2Windows. Originally posted by Leyukaka on 2026-11-27T20:32:12Z.


Part of #2935 (instruction coverage). Target branch main. I am taking it.

Gap. Captured compute programs write the high EXEC word with s_mov_b32 exec_hi, <constant>. The direct path accepts s127 as a move destination only on the wave64 path, so wave32 compute refuses it with "direct scalar move destination".

Measured on a local capture of 2,689 compute requests (counts and instruction shape only), with compile_dxil --jobs 8 gfx1013-direct-cs@36 --requests on main 6057071b:

  • 2 requests stop first there on main (s_mov_b32 exec_hi, 17 and exec_hi, 0x550055).
  • 3 more reach it once #3170 lets s_bitreplicate_b64_b32 exec through.
  • With the change, one of the two compiles (403 to 404; it is dispatched 178 times in one start-up run). The other stops next at "direct image opcode or descriptor modifiers" (image_store).

Plan:

  • In wave32 compute, store the value in s127 like any scalar word.
  • active() reads s126 only, so no lane is enabled. A later numeric read of exec_hi returns the stored value, as on hardware.
  • Wave64 keeps its current handling.

Tests: a hardware readback of the stored exec_hi and of a lane value under exec_lo, plus a wave64 container compile case.

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:6654039027 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/issues/3181). Originally posted by [Leyukaka](https://github.com/Leyukaka) on 2026-11-27T20:32:12Z. --- Part of #2935 (instruction coverage). Target branch `main`. I am taking it. **Gap.** Captured compute programs write the high EXEC word with `s_mov_b32 exec_hi, <constant>`. The direct path accepts s127 as a move destination only on the wave64 path, so wave32 compute refuses it with "direct scalar move destination". **Measured** on a local capture of 2,689 compute requests (counts and instruction shape only), with `compile_dxil --jobs 8 gfx1013-direct-cs@36 --requests` on `main` `6057071b`: - 2 requests stop first there on `main` (`s_mov_b32 exec_hi, 17` and `exec_hi, 0x550055`). - 3 more reach it once #3170 lets `s_bitreplicate_b64_b32 exec` through. - With the change, one of the two compiles (403 to 404; it is dispatched 178 times in one start-up run). The other stops next at "direct image opcode or descriptor modifiers" (`image_store`). **Plan:** - In wave32 compute, store the value in s127 like any scalar word. - `active()` reads s126 only, so no lane is enabled. A later numeric read of `exec_hi` returns the stored value, as on hardware. - Wave64 keeps its current handling. **Tests:** a hardware readback of the stored `exec_hi` and of a lane value under `exec_lo`, plus a wave64 container compile case. AI-assisted.
Sign in to join this conversation.
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#3181
No description provided.