Isolate WARP readback differences in a source-built subgroup compaction dispatch #762
Open
opened 2026-11-23 01:55:45 +00:00 by R0Y00
·
25 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#762
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 R0Y00 on 2026-11-23T01:55:45Z.
Why this advances the port
#656 verifies subgroup ballot-bit extraction, and #763 distinguishes adapters that lack SM 6.6. In a fixed-profile local compute replay, one record built a pipeline on both RTX and WARP. Its two controlled inputs matched the reference on RTX, while WARP returned different DWORDs. The cause remains open. A public subgroup compaction fixture would let contributors check the wave operations and the writeback separately.
Scope
Start from the optional SPIR-V bridge fixture and build one source-owned compute program. Give it a sparse per-lane predicate and disjoint output ranges per wave. Make the observed lane index and width, ballot mask, selected-lane rank and compacted writeback visible separately. Use the measured lane width when calculating the independent CPU reference. Keep the result independent of the scheduling order of workgroups or waves. Compare direct desktop HLSL and the SPIR-V-to-HLSL bridge under the same inputs where practical.
Acceptance
To claim, say whether you will implement the source fixture or independently test it on another backend. Refs #656 and #763.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T02:31:35Z.
#774 now gives a working source-built starting point in
tests/spirv_window/check.py: a ballot bit controls an address-window store, and clearing that bit changes DWORD 11 on app-local WARP. Its mask is constant. For this issue, keep that test as the baseline and make the new predicate vary across lanes. Compare the ballot words and rank before the compacted store, so a mismatch can be placed before or after address calculation.Imported from R0Y00/Xbox2Windows. Originally posted by FZNull on 2026-11-23T03:41:49Z.
Built the fixture and ran it. The difference is isolated, and it is not a WARP arithmetic bug: it is the wave width.
Fixture (PR #791,
tests/spirv_window/compaction.*plus--spirv-compaction): one 64-thread group, sparse predicate from a deterministic 64-bit mask, realOpGroupNonUniformBallot, with separate words for the observed lane index, observed width, ballot words per wave, first/count/last active lane, the selected lane's rank, the per-lane rank, and compacted payloads in wave-disjoint ranges, plus a guard tail that must stay0xc5c5c5c5. The CPU reference is recomputed at the width the shader reports.Result: both adapters match their width-aware CPU reference in all 328 words, two masks, bridge and direct-HLSL control: 0 mismatches, guards intact, repeated dispatches identical. The two negative controls (wrong ballot bit, shifted write index) are caught at the predicted first words 65 and 257 on both adapters.
The adapters differ first at word 4, the per-thread lane index: RTX 4060
0x00000004, WARP0x00000000; 259/328 words differ with mask A and 260 with mask B.D3D12_OPTIONS1.WaveLaneCountMin/Maxis 32/32 on the RTX 4060 and 4/4 on WARP, andWaveGetLaneCount()in the shader returns 32 and 4. A CPU model at width 32 gives the same first mismatch against the WARP readback. At its native 4-lane width WARP matches the independent model exactly, so there is no ballot, rank or writeback divergence there — a compaction kernel that assumes 32 lanes simply produces different DWORDs on WARP. That also fits #774 matching on WARP: constant-mask ballot-bit extraction is width-independent, a real ballot/compaction layout is not.Caveat, stated because it matters: I cannot replay the original record (it is not in the public tree), so this isolates a reproducible difference of the same class rather than proving that replay used a 32-lane assumption. The next step is to run that record through this fixture, or log
WaveGetLaneCount()in the replay and recompute its reference at the observed width.Repro:
Environment: Windows 11 Pro build 26300.10075, debug layer unavailable; RTX 4060 driver 32.0.16.2124 (32..32); WARP 10.0.26100.10068 (4..4); MSVC 19.50.35726, SDK 10.0.26100, DXC 1.9.2609.5, SPIRV-Tools v2025.5
262bdab, SPIRV-Cross57e4efc. No adapter here exposes a 64-lane wave, so the intra-wave 31/32 boundary is a capability skip; the 31/32 bit boundary is still covered across two 32-lane waves.AI-assisted.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T04:32:55Z.
#791 merged as
333562f. The public fixture matches all 328 words against the reference at the observed wave width on WARP and RTX 4060 for both masks and both backends. Recomputing at width 32 reproduces the first mismatch against the 4-lane WARP run. That establishes a source-built width-sensitive case. This issue stays open until the original replay records the shader’s observed width and checks the intermediate words against a reference at that width.Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T09:13:53Z.
#821 landed as
16d2356. The source-built fixture now also runs withcs_6_0. The GTX 1060, Windows 10 in-box WARP and app-local WARP runs observed widths 32, 4 and 8 and matched all 328 words in both shader paths. The original replay stays open. Capture the observed lane count there and compare the per-wave ballot, rank and compacted payload against a reference for that same width.Imported from R0Y00/Xbox2Windows. Originally posted by rasptum on 2026-11-23T16:16:14Z.
Independent Ampere run of the public compaction fixture (
tests/spirv_window/compaction.*,--spirv-compaction). The original replay was not run, because it needs data that is not public.Environment
2aa81a2629ca1d2364928461a0d6650fd77a52ac(currentmain, includes #791 and #821)10de:2503), driver 32.0.15.9636 (596.36)d3d12SDKLayers.dll10.0.19041.5794 present)setup-spirv-tools.ps1build: SPIRV-Tools v2026.4 (ef96ed76), SPIRV-Crossvulkan-sdk-1.4.357.0-39-gf11ba9f0XBOX2WINDOWS_ADAPTERCommands
Results (each cell covers dev and release, which gave identical output)
cs_6_0)cs_6_0)Negative controls, both masks, both presets. Each matched its mutated reference exactly and diverged from the original reference at the predicted word:
ballot_bitfirst mismatchwrite_indexfirst mismatchctest: dev 2/2 passed, release 2/2 passed, 0 failed, 0 capability skips, 0 timeouts. All 48 dispatches (24 per preset) reporteddebug_errors=0 debug_warnings=0.Not covered
offscreen_checkhas no switch for it. It enables the layer whenever SDK layers are present, so I did not run that variant.cs_6_0for both bridge and direct. No separate SM 6.6 compaction path exists on currentmain.Conclusion: Ampere (RTX 3060) runs at width 32 and matches the width-aware CPU reference in all 328 words, for both masks and both shader paths, in dev and release, with the debug layer on. Same-machine WARP matches at width 4.
AI-assisted.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T16:22:37Z.
Thanks. This Ampere result extends the public baseline to RTX 3060 width 32 and same-machine in-box WARP width 4, with both paths matching all 328 words. The mismatch at word 65 for the ballot mutation and 257 for the write-index mutation help distinguish those two failure modes.
The remaining public control is a width-64 run that crosses bit 31 to 32 within one wave. The original replay still needs its own observed width and the first differing ballot, rank or payload at that width. The two sets of evidence can be reported separately.
Imported from R0Y00/Xbox2Windows. Originally posted by lantiumBot on 2026-11-23T19:27:45Z.
Width-64 run of the public compaction fixture (
tests/spirv_window/compaction.*), unmodified tree: AMD Radeon RX 9060 XT observed one 64-lane wave, so the 31/32 ballot boundary is crossed inside a single wave. Data only, no fixture change. The original replay was not run; it needs data that is not public.Results (each cell covers
devandrelease, which gave the same lines)mask_ais(0x84218421, 0x18421842): bit 31 set, bit 32 clear.mask_bis(0x28421842, 0x84218421): bit 31 clear, bit 32 set. Withwidth=64 waves=1both ballot words belong to the same wave, and the width-aware CPU reference matched in all 328 words for both masks, including ballot, first, last, rank and the compacted payload.Negative controls, both masks, both presets
Each matched its mutated reference exactly and diverged from the original reference at the predicted word.
On the Radeon the ballot mutation shows up in both ballot words of the single wave (words 65 and 66), for example with mask_a: word 65
cpu=84218421 gpu=48124812, word 66cpu=18421842 gpu=24812481.ctest:
dev2/2 passed,release2/2 passed, 0 failed, 0 capability skips, 0 timeouts.Environment
0f0c3eb1f50f227ddc154ab7e081839628ff89b3, clean tree262bdab, SPIRV-Headersb824a46, patched SPIRV-Cross57e4efc, built withtools/setup-spirv-tools.ps1Not covered
AI-assisted (Claude Code - Fable 5.2 Medium); runs executed locally on the adapter above.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-23T19:30:22Z.
Thanks for the width-64 run. The RX 9060 XT exercised bits 31 and 32 in a single wave in both directions. Both masks matched the CPU reference for all 328 words, and the two controls separated ballot errors (word 65) from write-index errors (word 257). This completes the remaining public width-64 control alongside the width-32 RTX and width-4 WARP reports. Keep the original replay open for its observed width and first differing ballot, rank, or payload. We can compare those summaries without sharing the original input.
Imported from R0Y00/Xbox2Windows. Originally posted by ChazY11 on 2026-11-24T01:13:34Z.
Independent test on a third adapter: the fixture passes on WARP and RTX 5080, and fails on Intel Arc 140T
Claiming as an independent tester, not as the fixture author:
spirv_compaction_warpandspirv_compaction_hardwarealready exist (refs #656, #763), and the ask in the issue is to run them on anotherbackend. I ran them on a hybrid laptop where the discrete and integrated adapters sit on the same Windows install, so
the comparison costs one environment.
Results
Build: source
110e186(working tree24d5a0c, docs-only diff),devpreset,-DSPIRV_WINDOW_AS/VAL/CROSSpointed attools/setup-spirv-tools.ps1output.Tools: SPIRV-Tools v2025.5
262bdab4, SPIRV-Cross57e4efc+with the MinLod patch, DXC 1.8.2502.11(
dxcompiler.dllfrom SDK 10.0.26100), MSVC 14.44.35207, Python 3.12.10.OS: Windows 11 build 26300.9974, debug layer enabled in every run (
debug_errors=0 debug_warnings=0).spirv_ballot_extractspirv_compactionExact command, per adapter:
What fails on the Arc, exactly
The bridge path matches the CPU reference (
mismatches=0over 328 words, repeat identical). The direct desktop-HLSLcontrol then reports a different observed width and a readback that is not stable between two identical dispatches:
Two things are worth separating, and I am not claiming a cause for either:
mask, while RTX reports 32/32 and WARP 4/4. The fixture recomputes its CPU reference from the observed width, so
the width difference alone does not fail it — but it does mean the Arc answers
subgroup sizedifferently for aSPIR-V-compiled module and a DXC-compiled one.
readback. That is the failure the test reports, and it is the one I cannot explain from the fixture side.
Repetition:
spirv_compaction_hardwaregave FAIL, FAIL, FAIL on the Arc and PASS, PASS, PASS on the RTX 5080,so it is adapter-specific and stable on each adapter, not a flake in the harness. The 31/32 lane boundary that the two
masks exercise (
mask_asets bit 31 and clears 32,mask_bthe reverse) is inside the 16-lane waves the direct pathreports, so those lanes were exercised, not skipped.
A third fixture fails on the same adapter and may or may not share the cause:
spirv_sampler_views_hardware→Split sampler readback mismatch(RTX and WARP pass). I will file it separatelyunless you would rather keep it in this thread.
What I need to continue
preference), or is it itself the defect?
index/width words, the ballot, or the compacted slots?
compaction.pyalready writes each to its own word, so I candump the raw 328 words for both dispatches and put the diff in this thread.
the fixture currently raises rather than printing the two dumps.
I can run any follow-up on the same machine and paste the full log; I have no AMD adapter, so native 64-wide
subgroups remain uncovered here.
No game files, dumps or distribution links are involved: every input is generated by the repository's own fixture.
Imported from R0Y00/Xbox2Windows. Originally posted by ChazY11 on 2026-11-24T01:43:27Z.
The first dispatch of a freshly compiled module reports 16 lanes on this adapter; later dispatches report 32
I went after the "direct readback changed between identical dispatches" half of the Arc result, because the fixture
derives its CPU reference from the width the shader reports. A minimal probe — one group of 64 threads, no descriptors
in the data path, four words per thread — pins the intermediate that moves.
Run through the repository's own raw dump helper, which fills unwritten words with a known pattern, so the comparison
is word for word:
Two consecutive runs of the same module on the Intel Arc 140T (8086:7d51, driver 32.0.101.8132, Windows 11 build
26300.9974, DXC 1.8.2502.11, debug layer enabled,
debug_errors=0 debug_warnings=0):Field 1 is
WaveGetLaneCount, field 3 is the low ballot word. Each ballot is correct for the width the shaderreported in that run (16 lanes give
0x8421, 32 lanes give0x84218421), so this is not a wrong ballot: the widthitself moved.
When 16 appears
Four separately compiled modules — the probe above plus three copies whose only difference is an unused mask
constant, which changes the bytecode and therefore the driver's cache key:
Afterwards, 5 runs per module (each a fresh process): 32 in all 15. The RTX 5080 Laptop reported 32 on every run of
every module, and WARP reported 4, so only this adapter moves.
So the pattern is: the first dispatch of a module the driver has not compiled before often reports 16 lanes, and the
same module reports 32 from the second dispatch on. I have not determined what makes variant 1 start at 32; 3 of 4
fresh modules started at 16.
Why this matches the fixture's symptom
The compaction fixture dispatches the direct module once, computes the CPU reference from the width that dispatch
reported, then dispatches it again and compares. If the first dispatch reports 16 and the repeat reports 32, the two
readbacks differ in exactly the words that depend on the width (the compacted slots and their ranks), and the fixture
reports
direct readback changed between identical dispatches. That is also the shape of the width variance in thestandalone GPU check report (#1) on this adapter, and of the
bridge width=32 / direct width=16split I reportedearlier in this issue: the two shader sources are different modules, so they can land on different cache states.
What I would suggest, and what I need
visible instead of a mystery, and a width change between the two dispatches of a pair could be reported as a named
skip rather than a mismatch — the device is not producing a different result for the same wave, it is producing a
different wave.
--raw-uav-dump; I can sendthat as its own PR under
tests/spirv_window/. I have not added it without your word.This is measurement only: no fixture, expectation or build change was made, and the Arc result still stands as a
failure. The clamp-rounding report stays in #809, as you asked.
Imported from R0Y00/Xbox2Windows. Originally posted by ChazY11 on 2026-11-24T01:53:57Z.
Both deterministic masks on this adapter: 328/328 words, all four controls caught — with one anomalous attempt worth recording
The fixture stops on this adapter before the second mask, so I isolated the bridge path and reused the fixture's own
emit_bridge,run,reference,check_sourceandrun_control, so these numbers are the ones the test prints.Three consecutive full runs, same commit and tools, debug layer enabled, zero debug warnings and errors:
width=32 waves=2on the two adapters andwidth=4 waves=16on WARP. So the acceptance item "two deterministicmasks on WARP and one capable physical adapter, compare all intermediate words" is satisfied for this adapter as far
as the ballot, first/last lane, rank, selected lane and compacted payload arithmetic go — including the 31/32 mask-bit
boundary, which the two masks place on either side of a wave split.
The one anomalous attempt
The very first attempt of this same driver, on the Arc, failed inside the mask_b
write_indexcontrol with:That is the control's mutated readback disagreeing with its mutated reference at a lane index, not at a
compacted slot: the reference expects lane 19 where the GPU wrote 3, i.e. the low lane bits only. Three reruns of the
identical command then passed every mask and every control.
This is the same shape as the repeat failure and as my width probe (first dispatch of a freshly compiled module
reports 16 lanes, later dispatches report 32): a module compiled in that run produced a different lane mapping, and
because the control builds a fresh module too, it can hit the same window. I am recording the rate I observed — 1
failure in 4 attempts of this driver, with 3 clean reruns — rather than claiming it is fixed or deterministic.
What would make it falsifiable
Recording the observed width per dispatch (four numbers per run: width and lane range per label) would show this
directly instead of as a lane-word mismatch, and a run where two dispatches of one module disagree on width could be
reported as a named skip. That is the change I offered earlier; the current Arc result still stands as a failure, and
I have not altered any fixture or expectation.
Imported from R0Y00/Xbox2Windows. Originally posted by archielcqp-a11y on 2026-11-24T08:37:38Z.
Forced width-64 run of the public compaction fixture on app-local WARP 1.0.22. Data only, no fixture change. The original replay was not run; it needs data that is not public.
The fixture source is unchanged. A local wrapper ran
tests/spirv_window/compaction.pywith every DXC input copied to a temp file with[WaveSize(64)]inserted before[numthreads(64, 1, 1)], so WARP ran one 64-lane wave and bits 31 and 32 of the ballot fall inside that wave. Both the SPIR-V bridge HLSL and the direct HLSL went through the same insertion.Results
Unforced on the same machine,
spirv_compaction_warp(WARP 1.0.22, width 8) andspirv_compaction_hardware(RTX 3080, width 32) pass. Forcing width 64 on the RTX 3080 is not possible: pipeline creation returnsE_INVALIDARG(0x80070057), consistent with its 32..32 lane range.Relation to #145
On this same WARP 1.0.22 at forced width 64,
wave_shuffle_warpstill misroutes 64 of 64 affineWaveReadLaneAtreads. Here, ballot, per-lane rank, first/last active lane and the compacted writeback are all correct at that width. So the WARP 1.0.22 forced-wave64 defect is not in ballot or subgroup bookkeeping; it is limited to lane reads whose source lies in another 8-lane block.Environment
d2ac41559f99fddbb5f42858776df7377f8bcc1c; the working tree had unrelated local changes, none intests/spirv_window/compaction.*OFFSCREEN_AGILITY_620_DIRandOFFSCREEN_WARP_DIR10de:2216), driver 32.0.15.9174262bdab4), SPIRV-Cross57e4efcwith the pinned MinLod patch (tools/setup-spirv-tools.ps1)This report was prepared with AI assistance.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-24T08:44:25Z.
Thanks for running both paths at forced width 64 and retaining the two mutation controls. This rules out a failure in the public compaction fixture on that WARP build. Please keep the independent WaveReadLaneAt result under #145, and keep the original mismatch open until a source-built variant reproduces it. If the original result can be shared as aggregate evidence, the useful comparison is the first divergent output word and whether it depends on a cross-block lane read.
Imported from R0Y00/Xbox2Windows. Originally posted by ChazY11 on 2026-11-24T10:19:18Z.
Aggregate evidence: the first divergent word is a lane index, and it is not a cross-block read
Keeping the original mismatch open as you asked, and leaving the
WaveReadLaneAtresult to #145 — this is only thecomparison you named: first divergent output word, and whether it depends on a cross-block lane read.
Using the fixture's own direct module (
compaction.emit_direct), six modules the driver had not compiled before,each dispatched twice on the same adapter:
Word 16, field
lane,0x0in the first dispatch and0x10in the second. Word 16 is thread 16's ownWaveGetLaneIndex, which is the first lane of the second wave. It reads 0 while the module runs at 16 lanes and 16once it runs at 32. So the divergence does not depend on a cross-block lane read: no thread reads another block's
lane value. Each thread reports its own lane index, and the only thing that changed is how many lanes the wave has.
The 32 divergent
lanewords, 32rankwords and 10ballotwords are the downstream consequence: the second waverestarts at lane 0, so its ranks and ballot words shift with it, and the compacted payloads follow.
The control is inside this result: re-running the identical six modules a second time gives
first width=32, second width=32, repeat_differing_words=0, six times out of six. The flip needs bytecode the driver has not compiled before,so the same bytes are stable once cached — which is why the public fixture usually passes on this adapter and why the
failure is intermittent rather than constant.
Reproduce on any adapter:
The script only perturbs one mask bit per module so each run compiles new bytes; it does not assert anything and
writes nothing outside a temporary directory. The RTX 5080 Laptop on the same script reports
first width=32 second width=32for all six modules, so this is the adapter, not the module shape.No fixture, expectation or skip behaviour changed by me here, and I have not touched #145.
Imported from R0Y00/Xbox2Windows. Originally posted by ChazY11 on 2026-11-24T10:31:24Z.
The reproduction I used, so you can run it without me
Since the original mismatch stays open until a source-built variant reproduces it, here is the exact probe behind my
last two comments. It is a script, not a fixture, and it only prints — no expectation is changed anywhere.
Two things matter about the shape of it:
emit_directoutput is byte-identical across runs for a fixed mask, so a second run of thesame script re-uses modules the driver already compiled and reports
differing=0for all six. The seed perturbs onemask bit per module, which is what makes each module new to the driver. That is also the "control" I mentioned: same
bytes, second dispatch, width 32, nothing moves.
emit_directis the fixture's emitter, so this is the direct path's bytecode, not asynthetic shader;
field()andrun()are the fixture's own helpers, so the word indices match what the testprints.
On the Arc it reports six modules of
width 16->32withfirst_word=16 field=lane first=0x00000000 second=0x00000010, 32 lane words, 32 rank words and 10 ballot words differing. On the RTX 5080 Laptop all six reportwidth 32->32 differing=0.If you want this to become a fixture that fails deterministically on an affected adapter, the change is in
compaction.py(per-dispatch width in the output, and a width change between the two dispatches reported as a namedskip instead of a mismatch); I have not touched it, and I will leave the probe here unless you say otherwise.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-24T11:01:40Z.
Thanks for the fresh-versus-repeat control. This isolates a lane-width change on the Arc configuration independently of a cross-block read. Please keep it beside the original WARP case as separate evidence. The next useful WARP result would use the same source-built direct module and report the first divergent word, observed width and build for the first and repeated dispatches. Keep the existing strict checks.
Imported from R0Y00/Xbox2Windows. Originally posted by linusbrunotte-arch on 2026-11-24T13:13:13Z.
In-box WARP first-versus-repeat direct compaction check
Source:
ca4a98302544117caa71d85cd8c7e89f3749457f(main at test start). Windows 11 x64 build 26300.9974,offscreen_checkRelease built with Clang 23.1.6 in MSVC mode, Windows SDK 10.0.26100, DXC 1.9.2609.5. D3D12 debug layer unavailable. Backend: Microsoft Basic Render Driver (1414:008c), in-box WARP10.0.26100.9818.Follow-up to the requested first/repeat check. I used the six-mask direct-HLSL probe with fixed seed
13037. Each mask was built with the fixture’semit_directinto a distinct DXIL payload, then the same binary was passed tocompaction.run(..., "warp", dxil)twice. All 12 launches exited 0.8421e1fb / 18422aaf8421e1fd / 18422aac8421e1ff / 18422aad8421e1c1 / 18422ab28421e1c3 / 18422ab38421e1c5 / 18422ab0Each pair matched all 328 words. This is the direct first/repeat comparison for the recorded WARP build. The original replay remains open and the strict fixture is unchanged.
Codex (GPT-6) assisted with test execution and reporting.
Imported from R0Y00/Xbox2Windows. Originally posted by R0Y00 on 2026-11-24T13:22:51Z.
Thanks for running the requested first/repeat check. This establishes stable width 4 and identical 328-word output across all six repeat pairs on this WARP build. Please keep this alongside the earlier mismatch and Arc follow-up. The next useful comparison is the exact earlier failing input and module on this same build if they can be reproduced from the source-built fixture. The strict expectation stays in place.
Imported from R0Y00/Xbox2Windows. Originally posted by linusbrunotte-arch on 2026-11-24T13:38:08Z.
Follow-up to the request for the exact earlier case. The original WARP replay input and module are not in the public fixture. I used the exact public
mask_afrom the Arc direct-HLSL repeat failure as the closest source-built comparison.On the same local WARP setup as my previous report (in-box
10.0.26100.9818, Windows26300.9974, debug layer unavailable, renderer commitca4a98302544117caa71d85cd8c7e89f3749457f), I calledcompaction.emit_direct(directory, dxc, MASKS['mask_a'])with DXC1.9.2609.5, thencompaction.run(renderer, 'warp', dxil)twice on the same binary. Mask:84218421 / 18421842. Local DXIL SHA-256:a4f520f124c48d0f6f4fe8205ec93901b0f23043015f26e3952d4684e3b65770.Both dispatches exited 0, reported width 4, and each passed
check_sourceat 0/328 mismatches. Word 16 was00000000both times. All 328 words were identical across the pair, so there was no first divergent word.This is a matching public source/input comparison with a locally compiled module. The earlier Arc report used a different DXC, and the original WARP replay is still open. The strict fixture was unchanged. Codex (GPT-6) assisted with the run and report.
Imported from R0Y00/Xbox2Windows. Originally posted by Lifither on 2026-11-24T19:25:25Z.
Independent Polaris retest of the public SPIR-V compaction fixture.
Tested upstream
82749f0f84d9f8b571566fdf564d530e71f499aaon Windows 11 x64 build 26300.9974, Release, clang-cl 23.1.6 with/EHa, Windows SDK 10.0.26100, DXC 1.9.2609.5. Radeon RX 590 Series (1002:67df), driver 31.0.21923.1000. WARP: Microsoft Basic Render Driver (1414:008c), version 10.0.26100.9818. The D3D12 debug layer was unavailable on both adapters. SPIRV-Tools v2025.5 (262bdab4) and SPIRV-Cross57e4efcwith the project patch were selected from the pinned setup.Both tests passed, with zero failures or skips. The RX 590 reported width 64 (one wave) for both the translated and direct shaders, on both masks. WARP reported width 4 (16 waves). Each path matched all 328 reference words per mask, repeats were identical, and bridge and direct outputs agreed for each adapter. Both negative controls were caught for both masks on both adapters at the predicted first indices (65 for ballot bit, 257 for write index).
Source-built fixtures only. Codex assisted with testing and reporting.
Imported from R0Y00/Xbox2Windows. Originally posted by cawnr912 on 2026-11-24T19:37:34Z.
Independent run of the public SPIR-V compaction fixture on in-box WARP, an AMD RDNA 2 integrated GPU (device 164e) and an RTX 5070, all on one Windows 11 build 26200 machine.
Environment
mainatddeaa5ebd11cfc03248c72e5d0dbbe7d005bd20b, clean tree,devpreset (Debug)tools/setup-spirv-tools.ps1: SPIRV-Tools v2025.5 (262bdab4), SPIRV-Cross57e4efcwith the project MinLod patch1414:008c), in-box 10.0.26100.98181002:164e), driver 31.0.24002.9210de:2f04), driver 32.0.16.2124Commands
Result
3 passes, 0 failures, 0 timeouts, 0 capability skips.
spirv_compaction_warpspirv_compaction_hardwarespirv_compaction_hardwareOn every adapter,
mask_aandmask_beach matched the CPU reference for the bridge and the direct shader, and each repeat was identical. The bridge output equalled the direct output (bridge_equals_direct=true) for both masks. The Radeon integrated GPU ran at wave width 32 in this fixture. The RX 590 report ran at 64.Both negative controls caught their mismatch at the predicted word, for both masks, on all three adapters:
ballot_bitwrite_indexThis is a source-built fixture result only. It does not reproduce or explain the original replay difference. The replay's input and module are not part of the public fixture.
Imported from R0Y00/Xbox2Windows. Originally posted by RavenCurseBurg on 2026-11-25T15:53:30Z.
I ran the stock fixture three times each on Intel UHD Graphics 770 (32.0.101.5973), RTX 4060 (32.0.15.9579) and in-box WARP (10.0.26100.9711). Both masks matched all 328 words in both shader paths. All repeats were identical; reported widths were 16, 32 and 4 respectively. The ballot and write-index controls first differed at the expected words 65 and 257 on every run. Windows 11 26100.9711, DXC 1.9.2609.5, pinned SPIR-V tools, debug layer unavailable.
I’ll take a diagnostic follow-up while keeping the strict comparison outcomes. A changed repeat currently exits without naming the first different word or either width. A negative control also builds its mutated reference using the previous shader's width. In a separate diagnostic exercise I captured both real mutated modules on all three adapters, then deliberately paired each readback with a different recorded width: the Intel and NVIDIA cases blamed lane word 16 and WARP blamed lane word 4, even though each matched all 328 words of its own-width mutated reference. That cross-adapter exercise tests the reporting path; the nine normal runs above were stable.
I’ll report the first differing word, field and both widths on a changed repeat, and distinguish a changed width from a wrong result in the negative-control diagnostics. The repeat, bridge/direct and control mismatch paths will stay strict.
Imported from R0Y00/Xbox2Windows. Originally posted by stan495 on 2026-11-26T13:26:38Z.
AMD Radeon RX 7900 XTX (
1002:744c, 64-wide) and in-box WARP (10.0.26100.9818, 4-wide) run of the source-built subgroup compaction fixture (174f963d).This is a source-built fixture measurement only; it does not reproduce or explain the original private replay difference.
Environment
10.0.26200.9974)174f963d(working tree has an unrelated pre-existing modification intools/startup/debug_launch.py), presetrelease10.0.26100.0DXC (dxcompiler.dll1.8.2502.11) and localout/tools/spirv/bin/spirv-{as,val,cross}.exe$env:XBOX2WINDOWS_ADAPTER = "7900"):AMD Radeon RX 7900 XTX(vendor=1002 device=744c), driver32.0.32029.2010,debug_layer=enabledMicrosoft Basic Render Driver(vendor=1414 device=008c), driver10.0.26100.9818,debug_layer=enabledCommands
Results
2 passed, 0 failed, 0 skipped (
debug_errors=0 debug_warnings=0on every dispatch).bridge/direct,mask_a&mask_b)repeat=identicalbridge_equals_directAMD Radeon RX 7900 XTX(1002:744c)spirv_compaction_hardware0trueMicrosoft Basic Render Driver(1414:008c)spirv_compaction_warp0trueBoth negative controls were caught at their predicted first differing words for both
mask_aandmask_b:ballot_bitwrite_indexAI-assisted; commands listed were executed locally.
Imported from R0Y00/Xbox2Windows. Originally posted by Alexofbulgaria on 2026-11-27T01:53:43Z.
Intel Arc A770 subgroup-compaction comparison
Windows
26300.10075, Release atd3e3ea776e4fb32401f1eed3dc109fb477d9cbd8, DXC1.9.2602.17and pinned SPIR-V tools. A7708086:56a0/32.0.101.9175and WARP10.0.26100.10068. The debug layer was enabled and reported zero errors and warnings throughout.I ran the unmodified
spirv_compaction_hardwareandspirv_compaction_warpregistrations three times each. A770 3/3 passed; WARP 3/3 passed; no skips. For both masks and both shader paths, each run matched all 328 words. First and repeated outputs were identical. Observed wave widths stayed at 16 on A770 and 4 on WARP. The ballot-bit and write-index controls detected the predicted first differences at words 65 and 257 on both backends. This covers the public stock fixture at this pin. Source-built fixtures only. AI-assisted.Imported from R0Y00/Xbox2Windows. Originally posted by xiaoqi72665 on 2026-11-27T03:23:09Z.
RX 7900 XT (RDNA3) / in-box WARP subgroup compaction
Source-built public fixtures at
a4fae199517158fd443bfdd450f476b2c7b5f4c1, cleanmain, Debug (devpreset), Windows 10 build 19045.6466, Windows SDK 10.0.26100.0 DXC 1.8.2502.11. RX 7900 XT (1002:744c), driver 32.0.32029.2010; in-box WARP 10.0.19041.5794. D3D12 debug layer unavailable. SPIRV-Tools262bdab4/ Headersb824a462, SPIRV-Cross57e4efcwith the repository MinLod patch.Both registered
spirv_compaction_(hardware|warp)cases passed. On each adapter, both deterministic masks and both shader paths matched all 328 CPU reference words. Repeated dispatches were identical; bridge/direct results were identical.Both masks on both backends detected the predicted first mismatch at word 65 (ballot bit) and 257 (write index). All mutated readbacks also matched their independent mutated references exactly.
This covers the current source-built fixture only, not the original private replay.
Buhe (@xiaoqi72665). AI-assisted; tests executed on local hardware.