shader: name the whole-wave section step the simulation does not follow #121

Merged
Olima34 merged 1 commit from upstream-pr/121 into main 2026-11-26 18:09:23 +00:00
Olima34 commented 2026-11-26 17:30:45 +00:00 (Migrated from github.com)

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by Olima34 on 2026-11-26T17:30:45Z.


For the #4 shape "whole-wave section step the simulation does not follow" (7 refusals). This is a refusal split (diagnostic), not a lowering. The simulation drops whatever step it does not model, so nothing can be lowered safely without knowing the step.

What. emit::wave::simulate now also returns the first step it does not model (Section::why). section_inst refuses with "a whole-wave section step the simulation does not follow: " followed by one of:

  • an EXEC write that is no constant;
  • a scalar ALU result;
  • an instruction that is no VALU operation;
  • a v_readlane at a lane it does not know;
  • a VALU result in an SGPR;
  • a DPP step with lanes off;
  • a DPP control it does not model;
  • an operand or result modifier;
  • a v_permlane with computed lane selects;
  • a VALU operation it does not model.

When every step is modelled, the message ends "a value that is no reduction or prefix" instead. The shapes the simulation finds are unchanged. The doc says the first step not modelled is a hint, not proof.

Tests.

  • whole_wave_sections_name_the_step_they_do_not_follow (gfx_refusal): v_mul_f32 gives the VALU message, and v_mov_b32_dpp row_shr:1 gives "no reduction". It fails on main with the old message.
  • pipeline::pieces_tests::the_host_refuses_a_whole_wave_section_naming_its_step (victory-gpu): the same two programs on the native host's path. The container is built from the title's compute pieces (compute_container) and translated with the host's options (native::shaders::translate). It checks that the refusal string, the text the refusal log line shows, ends with the specific cause. It fails on main.

In the #110 Series S log: bf8467abe00be277 @0xc1c, d7cbf5c5680197fd @0xc58, f0c2cd42c9188fc3 @0x1ac. The next refusal report will say which step to model.

victory-shader (242) and victory-gpu (arm64) tests, Windows clippy and cargo xtask policy pass.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:issue:6631999622 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/pull/121). Originally posted by [Olima34](https://github.com/Olima34) on 2026-11-26T17:30:45Z. --- For the #4 shape "whole-wave section step the simulation does not follow" (7 refusals). **This is a refusal split (diagnostic), not a lowering.** The simulation drops whatever step it does not model, so nothing can be lowered safely without knowing the step. **What.** `emit::wave::simulate` now also returns the first step it does not model (`Section::why`). `section_inst` refuses with "a whole-wave section step the simulation does not follow: " followed by one of: - an EXEC write that is no constant; - a scalar ALU result; - an instruction that is no VALU operation; - a v_readlane at a lane it does not know; - a VALU result in an SGPR; - a DPP step with lanes off; - a DPP control it does not model; - an operand or result modifier; - a v_permlane with computed lane selects; - a VALU operation it does not model. When every step is modelled, the message ends "a value that is no reduction or prefix" instead. The shapes the simulation finds are unchanged. The doc says the first step not modelled is a hint, not proof. **Tests.** - `whole_wave_sections_name_the_step_they_do_not_follow` (gfx_refusal): `v_mul_f32` gives the VALU message, and `v_mov_b32_dpp row_shr:1` gives "no reduction". It fails on main with the old message. - `pipeline::pieces_tests::the_host_refuses_a_whole_wave_section_naming_its_step` (victory-gpu): the same two programs on the native host's path. The container is built from the title's compute pieces (`compute_container`) and translated with the host's options (`native::shaders::translate`). It checks that the refusal string, the text the refusal log line shows, ends with the specific cause. It fails on main. In the #110 Series S log: bf8467abe00be277 @0xc1c, d7cbf5c5680197fd @0xc58, f0c2cd42c9188fc3 @0x1ac. The next refusal report will say which step to model. victory-shader (242) and victory-gpu (arm64) tests, Windows clippy and `cargo xtask policy` pass.
LakshanSivakumar commented 2026-11-26 18:09:54 +00:00 (Migrated from github.com)

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by LakshanSivakumar on 2026-11-26T18:09:54Z.


Merged, thanks. #121 and #122 each added the same pieces helper to pipeline.rs, so I kept one, container_of (f57d5ad).

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7200127472 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/pull/121#issuecomment-7200127472). Originally posted by [LakshanSivakumar](https://github.com/LakshanSivakumar) on 2026-11-26T18:09:54Z. --- Merged, thanks. #121 and #122 each added the same pieces helper to `pipeline.rs`, so I kept one, `container_of` (f57d5ad).
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
LakshanSivakumar/Native-Victory-macOS!121
No description provided.