compute: lower the readfirstlane waterfall loop of a per-lane resource index (task list) #2636
Open
opened 2026-11-26 00:20:39 +00:00 by NiiRoZz
·
16 comments
No Branch/Tag specified
main
codex/indirect-large-backed-views
codex/word3-preflight-check
codex/vertex-table-two-records
codex/live-index-alias
codex/copied-vertex-buffer-srv
codex/windows-stage-test-output
codex/preserve-live-srv-retirement
codex/share-render-target-tracking
codex/sgd5-negative-offset-fixture
coverage-dashboard
codex/mesh-loose-root
codex/mesh86-cache-padding
codex/xmem-scatter-preflight
codex/mesh-depth-ps
codex/indirect-dispatch-refresh
codex/compute-container-index
codex/startup-compute-formatted-load
codex/compute-indirect-producer
codex/compute-atomic-soffset
codex/mesh-dual-handoff
codex/startup-run-sh-watcher-control
codex/queue31-page-alias
codex/indexed-indirect-compute-root
codex/typed-buffer-view-metadata
codex/translated-indexed-address-alias
codex/fixed-mesh-create-result
codex/xmem-section-lease
codex/startup-slot86-mesh-cache
codex/restore-mesh-barrier-iteration
codex/translated-indirect-upload-index
codex/xapu-completion-opt-in
codex/translated-indexed-rect
codex/translated-indexed-indirect
codex/startup-mesh-lds-integration
codex/startup-console-ms24
codex/startup-slot57-mesh-request
codex/indirect-copy-provenance
codex/present-color-producer-trace
codex/compute-dispatch-binding-trace
codex/translated-indirect-table-buffers
codex/indirect-copy-provenance-base
codex/mix-half-literal-source
codex/translated-indirect-draw
codex/xmem-scatter-diagnostics
codex/slot148-recording-upload
codex/slot70-loading-art-verified
codex/command-list-upload-arena
codex/recover-failed-command-list
codex/startup-heap-timing-notes
codex/align-audio-input-timeline
codex/synthetic-depth-export-control
codex/startup-texture1d-on-windows
codex/1629-packed-position-fixture
codex/cpu-srv-refresh
codex/stream-root-srv-draw
codex/audio-mixer-timer
codex/startup-reload-published-shader
codex/priority-integrate-1284
codex/guest-sixteen-page-record
codex/aot-placed-dxr-batch
codex/guest-directory-selection
codex/gamesave-enumerate-read
codex/readme-archive-to-pixels
codex/pe-placed-view-draw
codex/archive-directory-gpu
codex/slot133-dxr-build
codex/materialize-placed-vertex-view
codex/dstorage-directory-offsets
codex/xg-nine-bc-copy
codex/xg-slot10-bc64-arrays
codex/dxr-guest-address-readback
codex/gpu-va-high-bits
codex/clarify-diagnostic-startup-scope
codex/xg-six-levels
codex/typed-derived-blend
codex/english-legal-text-progress
codex/address-bc-4ks
codex/dstorage-bounded-file-read
codex/wide-srv-offsets-menu
codex/startup-memory-srv
codex/bound-view-tail
codex/language-selector-readback
codex/setup-menu-progress
codex/cpu-plane-refresh
codex/startup-ubyte-vertex
codex/presenter-window-selection
codex/startup-uniform-buffer-lane
codex/intro-loop-timing
codex/static-clzero-loops
codex/document-rtx-intro
codex/startup-insertq
codex/nv12-startup-texture
codex/stream-stage-draw
codex/startup-null-uav-format
codex/startup-draw-capture
codex/shorten-windows-checks
codex/dstorage-rfc1950
codex/startup-dump-fence
codex/pr1135-review-base
codex/startup-stream-requests
codex/startup-chroma-view
codex/readme-graphics-pipeline-streams
codex/static-crt-free-tls
codex/arc-140t-rtx-5080-laptop-gpu-reports
codex/main-startup-progress-entry
codex/signed-dxil-catalogue
codex/reloc-free-preferred-base
codex/quad-dpp-bit-mask
codex/raw-srv-bounds
codex/rx9070-31044-hardware-report
codex/gpu-page-source-provenance
codex/runtime-placeholder-interior
codex/gpu-copy-queue-tile-order
codex/pe-pin-external-providers
codex/xmem-placeholder-reservations
codex/xmem-shared-physical-pages
codex/pe-package-startup
codex/xmem-tools-memory-query
codex/cpu-stack-output-import
codex/pe-load-security-cookie
codex/record-three-bvh-retests
codex/cpu-rbp-frame-anchor
codex/xmem-default-startup
codex/record-rtx-3050-ti-9597
codex/docs-readme-start-here
codex/check-compute-mad24-truncation
codex/docs-discord-community
codex/bound-rcx-branch-mutants
codex/rtx5060ti-bvh-62114
codex/837-neutral-readme-disclaimer
codex/record-rtx-3070-ti
codex/title-neutral-public-wording
codex/exe-shadow-frame-submissions
codex/exe-shadow-runtime-chain
codex/readme-polish
codex/gpu-coverage-nov23
codex/spirv-minlod
codex/shadow-shim-device
codex/exe-two-shadow-frames
codex/shim-dispatch-cleanup
codex/fix-spirv-cache-probe
codex/sampler-use
codex/ballot-bit-extract
codex/packed-fma-release
codex/cpu-packed-fma-o2
codex/publish-coverage-dashboard
codex/mesh-cbv-binding-order
codex/spirv-window-fixture
codex/ps-e32-float-uint
codex/ps-cbuffer-reads
codex/fixed-profile-rescan
codex/shim-compute-integration
codex/readme-visible-coverage
codex/readme-research-navigation
codex/integrate-pr-256
codex/indexed-mesh
codex/sampled-coverage
codex/first-ms
codex/dual-ps
codex/ps-attribute
codex/compute-first
codex/ps-export
codex/readme-research-status
codex/ps-layout
codex/blast-window
codex/chart-caption
codex/reviewer-roles
codex/blast-aot
codex/archive-program
codex/crc-stream-program
codex/exe-image-data-chain
codex/local-cpu-fixture-coverage
codex/exe-bound-frame-chain
codex/exe-mapped-comparison
codex/contribution-dependencies
codex/exe-entry-aot
codex/bink-frame-heap-integration
docs/hardware-seven-reports
codex/bink-custom-heap
codex/bink-heap-callers
codex/discussions-entry-points
codex/gpu-community-batch-64
codex/ffx-scratch-writers
codex/generic-project-documentation
codex/ffx-dispatch-rcas
codex/four-windows-gpu-reports
codex/title-neutral-project-wording
codex/community-coverage-provenance
codex/rcas-packed-texels
codex/community-gpu-retests
codex/community-build-and-gpu-reports
codex/ffx-provider-loop
codex/ffx-recurrent-views
codex/ffx-recurrent-resource
codex/amd-wave64-reports
codex/ffx-backend-slots
codex/upscaler-device-init
codex/ffx-context-lifecycle
codex/ffx-version-query
codex/ffx-provider-contract
codex/typed-object-callback
codex/cpu-ordinal-import
codex/chained-cpu-ranges
codex/cpu-import-call
codex/cpu-direct-call
codex/cpu-leaf-aot
codex/community-project-status
codex/script-state-path-replay
codex/script-state-evidence
codex/bc7-resident-tail
codex/bcpack-mip-tail
codex/bc7-texture-draw
codex/asset-ranges
codex/pixel-constants
codex/pixel-aot
codex/pre-exe-workloads
codex/root-signature-device-coverage
engineering/packed-bvh-leaves
engineering/bvh-build-and-update
engineering/intake-root-roundtrip
community/gpu-check-release
community/english-contributor-entry
gpu-check-v0.1.0
Labels
Clear labels
No items
No labels
Milestone
Clear milestone
No items
No milestone
Assignees
Clear assignees
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#2636
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from R0Y00/Xbox2Windows. Originally posted by NiiRoZz on 2026-11-26T00:20:39Z.
Problem
Part of #2274 (section A, the
v_readfirstlaneproof item). Refs #1723.In one local run of the compute path,
v_readfirstlane_b32 requires a proven uniform sourcewas the first translator refusal of 19 compute programs, 938,948 dispatches. The source of the read was classified for each of them (counts only; not reproducible from the repository):v_log_f32/v_ceil_f32image_loadat uniform coordinates through a uniform descriptorv_and_or,v_bfe) before the shiftThe largest group is not a uniform source at all, so no extension of the uniformity proof (#2198, #2446, #2454, #2607, #2455) covers it. It is the loop a compiler emits for a non-uniform resource index:
vIis a per-lane word read from a buffer and shifted left by 5 (a heap record index).sKis a copy of exec made just before the loop. Each pass serves the lanes that share one index.Proposal
Lower this loop in the one-lane model as a single pass for the lane's own index. In the wave, a lane is active in exactly one pass, the one where
sIequals its ownvI, and in that pass every scalar the body derives fromsIis the value for that lane. So the model can run the body once withsIset to its own lane'svI, provided the shape is proven. Three separate pieces, each claimable on its own:v_readfirstlane sI, vIat a loop head only when: the next instruction isv_cmpx_eq_i32 sI, vI; the loop is closed bys_andn2_wrexec_b32 sK, sKthens_cbranch_scc1to the head;sKis a copy of exec made before the loop with no write between; the body is straight-line with no store, no LDS write and no loop-carried scalar; every scalar the body writes is dead at the loop exit;sIis not read before the compare. Anything else keeps a named refusal. Hand-assembled fixture with two lanes on different indices and two on the same one, plus near-misses (a store in the body, a scalar live at the exit,sKwritten in between).s_add_u32 sB, 0, src_sccafters_add_u32 sA, sHeap, sIis refused today assrc_scc with unverified SCCin 8 of the 10 programs once T1 is forced. Check whether #2577 already covers a carry from the instruction directly before it; if not, extend it for that adjacent form only.s_load_dwordx4is selected by a per-lane value, which in HLSL is a non-uniform resource index. #2580 covers an index read from a table buffer at a dispatch-constant position; this needs the per-lane form (2 of the 10 programs stop on the heaps_loadoffset refusal once T1 is forced). Runtime side: the bound heap range must cover every index a lane can produce, or the Dispatch is refused.The smaller groups, for whoever wants them:
v_log_f32andv_ceil_f32of a uniform operand are uniform (same argument asv_med3_f32in #2198). A local change with accepted and refused cases exists; the one program it lets through then stops atbuffer store through a modified descriptor, so it translates nothing on its own.image_loadat uniform coordinates through a uniform descriptor: needs a proof that the image is not written in the dispatch.Alternatives
WaveReadLaneFirst, a mask loop): possible, but it leaves the one-lane model for the whole program, and #145 records a WARP defect on non-uniform lane reads.Verification
Checklist
🤖 Generated with Claude Code
Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-26T00:37:06Z.
I’ll check T2 against current main, #1821 and the exact #2577 head. I’ll use a synthetic adjacent low-word add and high-word carry, exercise both carry values, and check an intervening SCC writer separately. I’ll post the first translation result or refusal for each revision so T1 and T3 can use a concrete dependency. This claim covers the T2 verification.
Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-26T00:40:04Z.
T2 is still needed for the adjacent pair. I fed synthetic SOP2 words through
gfx2hlsl.ComputePipeline(...).hlsl_cs()(one-thread group) on three independent checkouts. The decoded pair wass_add_u32 s20, s4, s5followed immediately bys_add_u32 s21, 0, src_scc.8972929coperand 'src_scc'e09daaa0src_scc with unverified SCC1530d637I also used literal low adds to distinguish the boundaries:
0xfffffffe + 1should give low0xffffffff, high 0, and0xffffffff + 1should give low 0, high 1. Both had the same refusal on each revision. Replacing the high input with an ordinary inline integer translated on all three. On both PR heads an intervenings_cmp_eq_u32made the high add read the compare's SCC; an intervenings_sub_u32kept the refusal. This locates the missing behavior at the low add's carry production. #2577's branch-target rule does not supply that carry.For reproduction, the register-input pair and terminator are the little-endian bytes
04 05 14 80 80 fd 15 80 00 00 81 bf. I’ll work on the adjacent compute address-pair case with independent low/high readbacks and intervening-writer controls. The waterfall selection and the resource lookup remain tracked under T1 and T3.Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-26T01:35:22Z.
I assembled a numeric T1 control and four near-misses as gfx1013 wave32 code with LLVM 15.0.7. On
f06646ba, all five reachv_readfirstlane_b32 requires a proven uniform sourcethroughComputePipeline(four threads, one group). The positive control is 84 bytes, SHA-256 prefixadc9be2b068f. Its input and output are raw buffers, so this exercises T1 independently of the T3 binding.After loading each lane’s key into
v5, with lane number inv0, the positive part is:A host-side wave-mask interpreter stepped the decoded loop. With keys
[64, 32, 64, 96], it served masks0x5, 0x2, 0x8and produced words[81, 48, 83, 114]. I checked all 81 four-lane tuples drawn from{0, 32, 0xffffffe0}against all 15 nonempty incoming masks. All 1,215 outputs and untouched inactive lanes agreed with(key + 17) XOR lanein uint32 arithmetic.There is another near-miss worth keeping in the proof. Replacing the two arithmetic instructions with just
v_mbcnt_lo_u32_b32 v7, exec_lo, 0makes the body depend on which other lanes share the index. The example then writes[0, 0, 1, 0]. An independent singleton execution would give[0, 0, 0, 0]. The two disagree in 495 of the 1,215 configurations. The currentv_mbcnthandler already requires a known mask. The T1 lowering should preserve that refusal and keep the grouped EXEC unavailable to instructions that use it as data. I also assembled the three specified near-misses (store inside the body,s23read after the exit, saveds21overwritten before the head). These are host-model results. The accepted translation and GPU readback remain to be demonstrated.Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-26T01:32:12Z.
With T2 merged in #2658, I’ll take the source-built fixture and independent per-lane reference for T1. I’ll assemble the
readfirstlane / cmpx / andn2_wrexec / cbranch_scc1loop with LLVM 15, compare a wave-mask interpreter against the per-lane result for repeated and different indices, and record current main’s first refusal. I’ll also check the body’s access to the active mask and scalar state at exit. This fixture work can proceed independently of T3’s heap binding.The host reference and active-mask counterexample are ready. I’m following through on the bounded numeric and fixed raw-buffer body in
gfx2hlsl.Stagewith the existing compute readfirstlane test entry points. I’ll exercise partial incoming EXEC, scalar liveness on exit paths and the first wrong readback word before proposing it upstream. T3’s resource selection and runtime bounds remain available as separate work.The T1 change and its three-adapter readbacks are in #2694. I’ll take the independent bounded-resource reference for T3. My 120-byte source-built program uses a four-record heap, masks each key with 3, then loads the record at
key << 5through the resource-heap pointer. The uniform control publishessrv 0 buf heap rootconst 0 2. The varying case reaches T1’s bound-range refusal. I’ll check it against four distinct D3D12 buffers and an independently written CPU reference, including a shader that always uses the first lane’s key. The runtime binding implementation is still available.Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-26T02:48:13Z.
The numeric and fixed-raw-buffer part of T1 landed in #2694 (
d382863b). I independently ran the host controls and Windows draws on WARP and RTX 4060 Laptop. Repeated and distinct keys, partial incoming masks, and the fixed-buffer loads matched. The wrong-reference controls produced the expected mismatches. Per-lane descriptor selection and mask-observing bodies are still outside this proof.Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-26T02:50:54Z.
I ran the bounded four-record reference with four physically separate D3D12 buffers on Intel UHD 770, RTX 4060 and WARP. The synthesized guest assembly, HLSL and C++ runner are available for the T3 implementation.
The 120-byte gfx1013 program reads the key from the input buffer, masks it with 3, and loads the 32-byte heap record at
key << 5through the resource-heap pointer. The T1 translator in #2694 refuses this at its bound-range guard. The 68-byte root-constant control publishessrv 0 buf heap rootconst 0 2anduav 0 table 1 16. LLVM 15.0.7 assembled both. Their binary SHA-256 prefixes aref32e1bfb3fc72454and25e2a001e9bb7f4c.The desktop reference binds one keys buffer and four SRVs. Each record stores
1000*(record+1)+17*lane. Five key tuples (forward, reversed, repeated, masked high bits and uniform) crossed with zero through four active lanes give 25 cases. The CPU independently checks all 320 words, including the inactive value 13 and 316 trailing sentinels.DXC emits
nonUniformIndex=truefor the marked dynamic handle andfalsewhen the intrinsic is removed. The fourth row is a device observation; the differing-key fixture still needs an explicit non-uniform resource index. This directly checks the desktop numeric reference. Guest heap range validation, resolving the four guest records, and actual guest-to-desktop binding in the runtime remain open.Windows 11 26100.9711, Intel
8086:a780(32.0.101.5973), NVIDIA10de:2882(32.0.15.9579), in-box WARP1414:008c(10.0.26100.9711), DXC 1.9.2609.5,cs_6_0, debug layer not enabled. The four public HLSL builds produced byte-identical DXIL to the programs used for the readbacks. Build the runner with the repository'stests/desktop_gpu.cpp,-Itests, D3D12 and DXGI; compilebounded.hlslasreference.cso,static-switch.cso(-DSTATIC_SWITCH),first-active.cso(-DFIRST_ACTIVE) andno-marker.cso(-DNO_MARKER). Run e.g.probe.exe Intel referencein the shader directory. Each invocation saves its hardware ID and result counts in a .receipt file.AI-assisted (Codex, GPT-6.2 Astra xhigh).
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-26T03:02:55Z.
Please keep the four-record oracle from the linked commit for T3. The 12/25 first-active mismatches distinguish lane-local selection from a wave-uniform shortcut. For the integrated runtime fixture, add one short-range control that omits the highest record and refuses before dispatch. Keep the independent DXIL handle check as well: on these three adapters dropping NonUniformResourceIndex did not change the bytes, so that mutation needs the nonUniformIndex metadata assertion.
Imported from R0Y00/Xbox2Windows. Originally posted by triggered02 on 2026-11-26T05:06:55Z.
Measured census data for this task list, from a diagnostic run of a source-built v_sad_hi_u8/v_msad_u8-era
main(fd033046) with the shader translator writing per-request status lines. Counts only; no game data, paths or shader text are included.Total requests seen: 3,162 — 51
ok, 3,111unsupported(2,683 of those are a cache-key mismatch, see below, so the shader-code refusals are ~428).The
readfirstlanefamily, exactly as this issue describes it:v_readfirstlane_b32 requires a proven uniform sourcecompute readfirstlane waterfall: body instruction s_bfe_u32 is not proven lane-localSo the waterfall shape (
compute: lower the readfirstlane waterfall loop of a per-lane resource index) is real at this census scale: 29 programs hit it as the primary refusal after a waterfall was detected, and 76 more are refused before that because the source was not proven uniform. Both are in the compute path.What would let me take a slice: the waterfall recognizer currently rejects a body whose
s_bfe_u32is not proven lane-local. If the intended scope is to admits_bfe_u32when its operands come from the lane-local saved masks (the same masks the loop already replays), that is a narrow addition with a synthetic fixture; if the scope is broader (any lane-local ALU in the body), it needs the lane-locality proof written down first. Say which, and I will build the fixture for it.AI-assisted; counts from the run's translate log.
Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-26T06:38:48Z.
I will take T6 for the two integer forms named here, v_and_or_b32 and v_bfe_u32 before a logical shift of a thread ID. I will check when the group bounds remove every varying bit, include nearby nonuniform refusal cases and run source-built fixtures on Intel UHD 770, RTX 4060 and WARP. This work starts from
e3cf6a91and is separate from the waterfall and generic wave-intrinsic changes.AI-assisted with Codex.
Imported from R0Y00/Xbox2Windows. Originally posted by stan495 on 2026-11-26T12:41:54Z.
Claiming T4 (
v_log_f32andv_ceil_f32of a uniform operand inUNIFORM_VALU) from the proposal.Plan:
v_log_f32andv_ceil_f32toUNIFORM_VALUintools/startup/gfx2hlsl.py(with existingVEC_Fmodifier checks and non-uniform source refusals intact).tests/startup_gfx2hlsl_readfirstlane_uniform_check.py(including source-modifier and non-uniform source controls) and add a source-built GPU dispatch readback check on WARP andAMD Radeon RX 7900 XTX(32.0.32029.2010) intests/startup_compute_readfirstlane_check.py.AI-assisted; I review and run all checks locally.
Imported from R0Y00/Xbox2Windows. Originally posted by R0D4X on 2026-11-26T13:04:40Z.
Claiming T5 (image_load at uniform coordinates through a uniform descriptor, proven unwritten in the dispatch).
Plan:
AI-assisted; source-built fixtures only.
Imported from R0Y00/Xbox2Windows. Originally posted by stan495 on 2026-11-26T13:10:15Z.
Claiming T5 (
image_loadat uniform coordinates through a uniform descriptor, proven read-only in the dispatch).Plan:
tools/startup/gfx2hlsl.py, extend the compute uniform-load proof (UNIFORM_LOADS/loads_after_exec_write/uniform_load_temps) toimage_load(kind == 'cs',exec_known, valid fixed unmodified table image descriptor with all 8 words intact and not inpipe.modified/other_modified/stored_images(), noimage_store/image_atomicin the dispatch, supported modifiers/dimensions withoutd16, and all coordinate VGPRsuniform_source).image_storein the dispatch, graphics stage, narrowed/loopEXEC, post-load join, and disabling theimage_loadproof).dxc+offscreen_check) with negative controls and verify readback on WARP and AMD Radeon RX 7900 XTX.Imported from R0Y00/Xbox2Windows. Originally posted by stan495 on 2026-11-26T14:11:35Z.
Claiming T3 (per-lane resource heap record index inside a compute
v_readfirstlane_b32waterfall loop).Plan:
tools/startup/gfx2hlsl.py: compute sound per-lane VGPR index upper bounds in CFG (v_and_b32,v_min_u32,v_bfe_u32,v_lshlrev_b32 ..., 5), allow a boundedresheaprecord load (s_lshl_b32 ..., 5+s_load_dwordx4 s[...], s[heap:0], offsetas well as the adjacent 64-bits_add_u32+s_add_u32 ..., 0, src_scc/s_addc_u32pointer-add form) inside proven compute waterfall loops, emitByteAddressBuffer rh[N] : register(t0, space2);withrh[NonUniformResourceIndex(...)], and publishresheap <N> 2in the compute manifest while keeping unbounded / non-heap / store / modified-descriptor forms refused.src/startup_stubs/translated_sampler_bindings.h&src/startup_stubs/d3d12_compute_dispatch.inl: parseresheap <N> 2intocreate_translated_root(t0..t{N-1}, space2) and verify every record0..N-1inpass.title_view_heap(resizing the dispatch view array cleanly and refusing beforeDispatchwhen the bound heap range omits any reachable record or holds an invalid descriptor).12/25first-active mismatches), add independent DXCcs_6_0DXILnonUniformIndexmetadata checks (NonUniformResourceIndexpresent vs omitted), translator/CFG negative controls, and an end-to-end stand-inDispatchfixture including the short-range negative control omitting the highest record onWARPandAMD Radeon RX 7900 XTX(with D3D12 debug layer enabled).Imported from R0Y00/Xbox2Windows. Originally posted by Not-Saii on 2026-11-26T16:19:57Z.
Census of the
v_readfirstlane_b32 requires a proven uniform sourcerefusals on currentmain(5a41adba), from one local set of slot 67 compute requests re-keyed to this revision. Counts only; the inputs are private and not attached.511 of 2,689 compute requests stop first at this refusal. I classified each one by the last instruction that writes the source VGPR before the read:
v_add_nc_u32 vN, vN, vNafterbuffer_load_dwordandv_and_b32(record word masked to 24 bits, plus a small per-lane term)v_mov_b32 vN, -1in one arm of an exec-masked if/else, where the other arm writes the same masked record wordbuffer_load_format_x(idxen)v_cvt_u32_f32/v_cvt_i32_f32image_load(T5 shape, #2842 / #2866)The first two rows are one source construct, 419 requests (82%):
0xffffff,-1on the other arm.After the arms rejoin and exec is restored, the program runs:
There is no
v_cmpx_eq/s_andn2_wrexecloop after the read, so this is not the T1/T3 waterfall. The compiler takes the first active lane's value as the index into 116-byte constant-buffer records. Nothing in the program makes that value uniform: it comes from per-lane loads, and one arm substitutes-1. I expect it is uniform in the data the title actually supplies, not provably so.So no extension of the uniformity proof covers this group. The options I see, none of them a small slice:
WaveReadLaneFirstin a wave-level lowering for this one shape. This leaves the one-lane model, the desktop wave is not the guest wave, and #145 records a WARP defect on non-uniform lane reads.readfirstlane of a per-lane record word used as a constant-buffer index, so the census separates it from the proof gaps.Which of these, if any, is in scope? Option 3 is a small diagnostic change I can take on its own.
AI-assisted (Claude Code).
Imported from R0Y00/Xbox2Windows. Originally posted by Not-Saii on 2026-12-01T02:29:30Z.
#3692 extends the uniform-load proof behind
v_readfirstlane_b32 requires a proven uniform source.What it changes: a uniform compute buffer load past the entry block is now also recomputed when EXEC is narrowed but proven nonempty on every path. That covers the fallthrough of
s_cbranch_execz, the taken edge ofs_cbranch_execnz, and the entry mask carried around a narrowing. Under a narrowed EXEC the address VGPR still needs its recomputable expression. The PR has accepted cases, refusal controls (including a lane-varying address) and a control with the proof disabled.What it leaves alone: the per-lane record word read as a constant-buffer index, described in the census comment above, is not uniform and stays refused. It is still most of this refusal.
Local census (counts only):
The replay of the 223 already-translated requests showed unchanged results and manifests. Not measured: a GPU readback of the new path.
AI-assisted (Claude Code).
Imported from R0Y00/Xbox2Windows. Originally posted by SimSalabimse on 2026-12-01T10:30:51Z.
I'll take the leftover first-refusal group on #2644: a lone
v_readfirstlane_b32of a per-lane record word, thens_and_b32/s_mulk_i32/s_buffer_load_dword*through a bound buffer, with nov_cmpx_eq/s_andn2_wrexecloop. On the console every active lane gets the first active guest lane's index and loads that one record, so I'll lower it as that exact broadcast (WaveReadLaneAtof the VGPR atfirstbitlowof guest EXEC, including the wave64 half exchange where needed). After the broadcast the key is wave-uniform. If the host wave cannot be proven to match the guest wave, or the offset, descriptor or uses cannot be proven, it stays refused with a named reason — not a per-lane approximation. Source-built fixtures only, including two lanes on different indices (both must see the first active lane's record), a case where the first lane is inactive in EXEC, and those refusals.AI-Assisted