shader: lower pixel structured-to-raw buffer loads #3100
No reviewers
Labels
No labels
accessibility
awaiting author
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
priority: P0
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/R0Y00--Xbox2Windows!3100
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-3100"
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?
@SimSalabimse on GitHub · 2026-11-27 15:10 UTC · original
SimSalabimse:cursor/ps-raw-descriptor-conversion→main· +901 −39 · 14 files · 7 commits · openChange
Since #2910, a non-indexed MUBUF load in a pixel stage through the standard structured-to-raw descriptor conversion is refused as
buffer load through a modified descriptor.load_descriptor()already accepts that shape, butraw_descriptor_alu()only ran for compute and vertex stages.This change:
raw_descriptor_alu()in a pixel stage as well, so the four conversion words are tracked the same way as for compute and vertex stages.NUM_RECORDS * stride(NUM_RECORDS * max(stride, 1)when the stride extract was clamped). A wrapped address reads as zero.byte_count+min1tag when that extract was clamped. Stores already accepted either product; they now match both tags explicitly.idxenloads refused under their current messages.A stride-only clear still lowers as an unbounded raw load, as in compute and vertex stages. Compute and vertex load emission is unchanged.
The graphics stand-in fills
strideand does not yet publishnumrecords, so a completed title pipeline still needs that constant before a draw applies the bound. The offscreen fixture supplies both.Verification
Commit under test:
185b7decd0e0cb0bf359990c6a5dc6ead9e03dc7, rebased onto upstream main77d1ba4d63ba31abaf4ca3635d4159189a423201.A source-built pixel fixture converts a table descriptor and reads it with
buffer_load_dword ... offenat four offsets, including one word pastNUM_RECORDS * stride. Negative controls, each refused by name: byte count missing, OOB step missing, in-place word rewrite, and anidxenload. A clamped extract usesmax(stride, 1) * NUM_RECORDS. A draw readback is compared with a CPU model of the same product. Dropping the bound must read the word past the limit.The Mesh57 upload-range path constructs its indirect buffer view with
indirect_buffer_view(range.resource, range.offset, range.bytes, 0u, 0u, true, 0), so the upload flag cannot shift intorecords. The pixel fixture asserts that construction.Windows test PC (MSVC,
--preset dev,-j 1), at185b7dec:6/6 passed, ctest exit 0:
native_fixed_mesh57_buffers_warp,native_fixed_mesh57_buffers_hardware,startup_gfx2hlsl_ps_raw_descriptor_udsrc,startup_gfx2hlsl_ps_raw_descriptor,startup_gfx2hlsl_ps_raw_descriptor_warp,startup_gfx2hlsl_ps_raw_descriptor_hardware. Build exit 0.Earlier on
c0d43994, the same worktree ranstartup_gfx2hlsl_ps_raw_descriptorandstartup_compute_dispatch_input_(6/6, exit 0). On an earlier head the fullstartup_gfx2hlsl_list was 379/379, exit 0.The fixtures are hand-assembled gfx1013 words. No game files or captured programs.
Checklist
Fixes #3064
AI-assisted (Cursor)
@R0Y00 on GitHub · 2026-11-27 16:15 UTC · original · requested changes
Independent Debug and Release
/O2each passed 3/3 (ctest --test-dir <build> --no-tests=error -j 1 -V -R '^startup_gfx2hlsl_ps_raw_descriptor', builtoffscreen_check), on551708c4integrated over300b93f0(tree23601ed0692b940e59b6f2515077a0734a34099a). The ordinary address case and the existing bound-drop mutant behaved as expected.Two added source-built probes expose gaps:
ud 5andudsrc 4 numrecords 0.load_translationinsrc/startup_stubs/d3d12_draw.inlskips the unrecognized source and sizes the root constants from the four accepted entries. I reproduced that exact omission with the offscreen fixture by callingdraw_once(..., constants[:-1], expected_words()). The draw succeeded through PSO creation with no debug warnings or errors. WARP returned four zeros, and RTX returned3f800000,40800000,41000000,deadbeefinstead of3f800000,40800000,41000000,00000000. Please bind the count or keep the unsupported ordinary draw on an explicit refusal path. A synthetic regression should exercise one of those two outcomes through the manifest loader.a + payloadafterahas already been truncated. In the same fixture, replace the instructionv_mov(0, 0)withstruct.pack('<I', 0x7e0002c4)to makev0=0xfffffffc. At immediate offsets 12, 28 and 32, the generated HLSL wraps the byte address to 8, 24 and 28 before testing it. Both WARP and RTX then read40400000,40e00000,41000000from the wrong portion of the view. Please check overflow when forming the initial byte address and add a guard for this case. The RDNA 2 ISA, §8.1 and Table 35 describes the immediate-plus-VGPR offset and raw bounds check.Windows
26200.9974, SDK/DXC10.0.26100.0, WARP10.0.26100.9818, RTX 4060 Laptop driver32.0.16.1656, D3D12 debug layer enabled.@KelboLive on GitHub · 2026-11-27 18:54 UTC · original · approved these changes
@tedin7 on GitHub · 2026-11-27 21:52 UTC · original · reviewed
Reviewed head
551708c42(Linux, Python only: no Windows run on my side).What works:
python3 -B tests/startup_gfx2hlsl_ps_raw_descriptor_check.pypasses at the head: the four controls are refused by name and the CPU model gives3f800000,40800000,41000000,00000000.raw_descriptor_alu()in the pixel stage is the right fix. The conversion words are tagged the same way as in compute and vertex stages, andraw_conversion_shapes()keeps the clamped and unclamped products apart.buffer_load_dword*matches the raw out-of-range rule for OOB_SELECT 3. The "RDNA 2" ISA guide, 8.1.8 Table 37 and 8.1.5, describes the converted NUM_RECORDS as a byte count.One more gap, besides the two already reported (the
numrecordsentry the runtime drops, and the wrap after truncation):tbuffer_load_format_*now gets through unbounded.tbuffer()reachesload_descriptor()throughbuffer_address(), so a pixeltbufferread through the converted descriptor now passes the check and setsraw_load_bound. But onlyop_buffer_load_dwordreads that bound. Source-built case: in your fixtureprogram(conversion()), replace the fourbuffer_load_dwordreads with onetbuffer_load_format_x v1, v0, s[16:19], 0 format:[BUF_FMT_32_FLOAT] offen offset:32. That is the word right pastNUM_RECORDS * stride = 32.db28a796, it is refused:buffer load through a modified descriptor.551708c42, it translates asa = v0 + 32; v1 = r0.Load(a);. There is no bound and nostride/numrecordsentry, so it reads0xdeadbeefwhere the hardware returns 0.Two ways to fix it. Apply the same bound in
tbuffer()(andload_format()), with one byte count per element. Or keepraw_conversion_ok=Falsefor the MTBUF path, so it stays refused as before. A control for this case in the existing check would lock it in.Commands run:
(
probe_tbuffer.pyimports your check module and builds the program above:smem_load_x4(DESC, 8) + conversion() + v_mov(0, 0) + <MTBUF word> + s_waitcnt + exp_mrt0(1, 1, 1, 1). The MTBUF word is op 0, FORMAT 22, offen, offset 32, srsrc s[16:19], soffset inline 0.)AI-assisted; commands listed were executed locally.
@rasptum on GitHub · 2026-11-27 21:55 UTC · original · reviewed
Review of
551708c4. Comment only.The translator part is good. It turns the pixel structured-to-raw descriptor conversion into a raw load with a bound. Everything else that touches those words still refuses. I tried 17 bad variants locally (wrong masks, wrong constants, words from a second descriptor, steps out of order) and all of them refused.
Blocking: the draw never fills
numrecords. The new stage asks forudsrc N numrecords <srv>. Theudsrcparser ind3d12_draw.inlonly knowsrect,basevertex,startinstance,rootconst,stride,d16unorm16,descword3andmrtbits. So the entry is never added, and because of thei == tr.uds.size()check, everyudsrcafter it is dropped too. In a real draw that means either the root signature doesn't match the shader, or the limit reads 0 and every converted load returns zero, with no warning. Fix: fillnumrecordsfromwords[2]of the table SRV, the waystrideis filled, or refuse unknownudsrckinds. The--startup-raw-buffertest fills its constants by hand, so it can't catch this.Should fix:
soffset, and the out-of-place (s_movcopy) form;Nits: unaligned addresses lose their low two bits without a refusal. The DW1 swizzle bits, ADD_TID and the DW3 format are kept but never checked; one line in the docs would cover it.
Ran on this head:
tests/startup_gfx2hlsl_ps_raw_descriptor_check.pypasses, with all 4 controls refusing.tools/run_checks_parallel.pyovertests/checks/python-linuxpasses 235/235. CI is green.@Leyukaka on GitHub · 2026-11-27 22:45 UTC · original · edited 2026-11-27 22:54 UTC
Review of
551708c4. Comment only. Edited: I have since built and run it; see the measurement below.Beyond what is already reported here (the dropped
numrecordsentry, the wrap after truncation, MTBUF without the bound, and the extra test cases), I found one small thing:--startup-raw-bufferaccepts 1 to 64 entry constants (tests/offscreen_check.cppandtests/startup_flat_param.cpp). The root signature puts them in one 32-bit-constants parameter and adds a one-range descriptor table, which costs one more DWORD. With 64 constants that is 65 DWORDs, over the D3D12 limit of 64. Measured on551708c4merged overmain14d56502: with the fixture padded to 63 constants the draw passes on WARP and on an RTX 5080; with 64,CreateRootSignaturefails with0x80070057("Create raw buffer root signature failed") on both. Capping it at 63 would fix it. The 1..64 bound is unchanged at327d134c. The fixture in this PR uses fewer, so it is not affected.I also checked two things that are not problems in this PR:
s_buffer_load_dwordthrough the converted quartet is not refused. Butop_s_buffer_load_dwordtakes the descriptor key without checking for modifications in any stage onmain, so this PR does not introduce it.main, and the PR tests it on purpose.AI-assisted.
@pigalot on GitHub · 2026-11-27 22:55 UTC · original · requested changes
I tried to review
327d134cmerged overmain4b0350ea. The merge is clean (tree90ef8851) andgit diff --cached --checkis clean, but the stand-in does not compile. This matches theBuild and test on Windowsfailure on this head.Finding:
IndirectBufferViewinitialisers don't match the new field order.stride, records, upload, withUINT records = 0;added beforebool upload = false;.indirect_table_bufferpass the values in the other order, as{..., stride, true, records},{..., stride, false, records}and{native, offset, bytes, stride, upload, records}.Even with narrowing allowed,
recordswould land inuploadand the upload flag inrecords.Suggested direction: declare
recordsafterupload, so the existing initialisers line up. Or swap the last two values in the three initialisers. The draw path that readsrecordsshould then be covered by thenumrecordsmanifest case you added.Earlier findings. I read
327d134cagainst the requests on551708c4. Because the stand-in doesn't build, I couldn't run the Windows fixture, so none of these is confirmed yet:numrecordsdropped by the loader (R0Y00 1, rasptum):accept_udsrc_linenow acceptsnumrecords, and an unknownudsrcmakesload_translationrefuse the manifest instead of skipping it.tbufferpassesraw_conversion_ok=False, so a typed load through the converted descriptor stays refused.I'll run the fixture and the
0xfffffffcand MTBUF probes once the stand-in builds.Verdict: request changes on
327d134c, because the head does not compile.Environment: Windows 11 25H2 build 26200.9974, MSVC 19.52.37029, Windows SDK 10.0.28000.0.
CI:
Build and test on Windowsfails on327d134cwith the same C2397 errors.This reply was AI-assisted.
@pigalot on GitHub · 2026-11-27 22:56 UTC · original
Follow-up to the changes-requested review on
327d134c(same trial tree90ef8851overmain4b0350ea), with two additions.A second blocker:
startup_gfx2hlsl_ps_raw_descriptorneedsg++on Windows.check_udsrc()builds its driver withg++unconditionally. The test is registered for Windows CTest as well as in thepython-linuxlist, so on a Windows host withoutg++it fails before any check runs. The_warpand_hardwarevariants callcontrols()first, so they fail the same way:CI never reaches this step because the build fails first. Possible directions (unconfirmed): skip the driver when
g++is missing; build it as a small CMake test target; or useclon Windows.The translator fixes run clean. With only the
g++step stubbed out, every case incontrols()passes:v0 = 0xfffffffcwrap at offsets 12, 28 and 32 reads 0;tbufferload is refused withbuffer load through a modified descriptor;soffsetand thes_mov-copied descriptor all pass;Still open (non-blocking): Leyukaka's limit.
tests/offscreen_check.cppandtests/startup_flat_param.cppstill accept 64 entry constants. With the descriptor table that is 65 DWORDs, over the 64-DWORD root-signature limit.This reply was AI-assisted.
@pigalot on GitHub · 2026-11-27 22:57 UTC · original
One more blocking item on
327d134c, which I left out of the review above.check_udsrc()intests/startup_gfx2hlsl_ps_raw_descriptor_check.pyalways builds its driver withg++(line 409).controls()calls it, and so do the no-argument anddrawmodes. All three tests are registered in the Windows CTest block:startup_gfx2hlsl_ps_raw_descriptor,_warpand_hardware. On a Windows host with nog++onPATH, like this one, all three fail before any check runs:Possible directions, none of them tried:
clon Windows;This reply was AI-assisted.
@pigalot on GitHub · 2026-11-27 23:23 UTC · original · approved these changes
Retested
587a3decintegrated overmain2e12dd8e(tree8448e705). The merge is clean andgit diff --cached --checkis clean.My changes-requested review on
327d134c.IndirectBufferViewfield order: addressed. All six construction sites now go throughindirect_buffer_view(resource, offset, bytes, stride, records, upload), which assigns by member name. That covers the three inindirect_table_bufferand the alias return that only passed four values. It also covers the two incompute_root_srv_buffer, where{..., 0, true}had been compiling silently withtrueinrecordsanduploadleft false.d3d12_xs_shimbuilds indevandrelease.g++on Windows: addressed. The udsrc cases are nowtests/startup_udsrc_line_check.cpp, built as the CMake targetstartup_udsrc_line_checkand registered asstartup_gfx2hlsl_ps_raw_descriptor_udsrc. The Python check gets the built binary throughX2W_UDSRC_CHECK. A direct run compiles the same source withclon Windows andg++elsewhere.numrecordsloader fix are covered by the mutants below.What I traced. In a pixel stage the full conversion now matches either
byte_countorbyte_count+min1. The load is bounded per dword bya + 4(i+1) <= lim, wherelimis the 32-bit product of the view'sstride(ormax(stride, 1)) andnumrecordsentry constants. Each address term is added with an unsigned carry check.tbufferpassesraw_conversion_ok=False. On the stand-in side,recordsis filled from descriptor word 2 in both branches and copied intorecord_counts[i], and thenumrecordsudsrc reads it. An unknown udsrc kind or an index gap now makesload_translationrefuse the manifest; it used to skip the line.What I ran. I built
d3d12_xs_shim offscreen_check startup_udsrc_line_checkindevandrelease, then ranAll 9 pass in Debug and in Release
/O2, with no skips. Bothstartup_gfx2hlsl_ps_raw_descriptor_hardwareruns read back3f800000,40800000,41000000,00000000for DXC and for FXC.startup_flat_param_hardwarereportsdebug_errors=0 debug_warnings=0for every case. I also ran the 155startup_gfx2hlsl_*tests that have no_warp/_hardwaresuffix, plusstartup_flat_param_controls, indev: 156/156 pass.Negative control and mutants. Each mutant was run against the tests above. The C++ ones were rebuilt in
dev.tools/startup/gfx2hlsl.pyback tomain_ps_raw_descriptor,_warpand_hardwarefail;_udsrcstill passesudsrc stridemanifest expectation)tbufferaccepts the conversiontyped buffer load: translated)<= lim→< limnumrecordsconstant readsstrides[]check_udsrc)udsrc driver exit 4)indirect_buffer_viewcallcompute_root_srv_bufferpassesrecords 1, upload falseRestored and rebuilt afterwards; the restored build passes again and
git diff --quietis clean.Non-blocking.
recordspath has no runtime test. The draw fixture binds throughoffscreen_check, not the stand-in. On the stand-in side onlycheck_udsrc()'s source assertions cover it, so a wrong argument order at anindirect_buffer_viewcall site still passes. The same holds for thecompute_root_srv_bufferfix, which is a real behaviour change:uploadused to be false on that path. A CPU-side check ofindirect_table_bufferorcompute_root_srv_buffer, or an indirect-draw case throughd3d12_xs_shim, would pin it.run_startup_raw_bufferandcheck_startup_raw_bufferaccept up to 64 entry constants. With the descriptor table that is 65 DWORDs, over the 64-DWORD root-signature limit. The fixture itself uses far fewer.551708c4. It also says the stand-in "does not yet publishnumrecords", but this head does.Verdict: approve on
587a3dec. This supersedes my changes-requested review on327d134c. R0Y00's changes request on551708c4still needs its own sign-off, so I'm not merging.Environment: NVIDIA GeForce RTX 5090 driver 32.0.16.1088, Windows 11 25H2 build 26200.9974; MSVC 19.52.37029; SDK 10.0.28000.0 DXC and FXC (the ones CTest picked up); Python 3.12.10; D3D12 debug layer on in
startup_flat_param_hardware.CI:
Build and test on Windowspasses on587a3dec;Run platform-independent Python checks on Linuxpasses too, so theg++path builds there.This reply was AI-assisted.
@pigalot on GitHub · 2026-11-27 23:28 UTC · original · requested changes
Retested
587a3decintegrated overmain2e12dd8e(tree8448e705). The merge is clean andgit diff --cached --checkis clean.My changes-requested review on
327d134c.IndirectBufferViewfield order: addressed. All six construction sites now go throughindirect_buffer_view(resource, offset, bytes, stride, records, upload), which assigns by member name. That covers the three inindirect_table_bufferand the alias return that only passed four values. It also covers the two incompute_root_srv_buffer, where{..., 0, true}had been compiling silently withtrueinrecordsanduploadleft false.d3d12_xs_shimbuilds indevandrelease.g++on Windows: addressed. The udsrc cases are nowtests/startup_udsrc_line_check.cpp, built as the CMake targetstartup_udsrc_line_checkand registered asstartup_gfx2hlsl_ps_raw_descriptor_udsrc. The Python check gets the built binary throughX2W_UDSRC_CHECK. A direct run compiles the same source withclon Windows andg++elsewhere.numrecordsloader fix are covered by the mutants below.What I traced. In a pixel stage the full conversion now matches either
byte_countorbyte_count+min1. The load is bounded per dword bya + 4(i+1) <= lim, wherelimis the 32-bit product of the view'sstride(ormax(stride, 1)) andnumrecordsentry constants. Each address term is added with an unsigned carry check.tbufferpassesraw_conversion_ok=False. On the stand-in side,recordsis filled from descriptor word 2 in both branches and copied intorecord_counts[i], and thenumrecordsudsrc reads it. An unknown udsrc kind or an index gap now makesload_translationrefuse the manifest; it used to skip the line.What I ran. I built
d3d12_xs_shim offscreen_check startup_udsrc_line_checkindevandrelease, then ranAll 9 pass in Debug and in Release
/O2, with no skips. Bothstartup_gfx2hlsl_ps_raw_descriptor_hardwareruns read back3f800000,40800000,41000000,00000000for DXC and for FXC.startup_flat_param_hardwarereportsdebug_errors=0 debug_warnings=0for every case. I also ran the 155startup_gfx2hlsl_*tests that have no_warp/_hardwaresuffix, plusstartup_flat_param_controls, indev: 156/156 pass.Negative control and mutants. Each mutant was run against the tests above. The C++ ones were rebuilt in
dev.tools/startup/gfx2hlsl.pyback tomain_ps_raw_descriptor,_warpand_hardwarefail;_udsrcstill passesudsrc stridemanifest expectation)tbufferaccepts the conversiontyped buffer load: translated)<= lim→< limnumrecordsconstant readsstrides[]check_udsrc)udsrc driver exit 4)indirect_buffer_viewcallcompute_root_srv_bufferpassesrecords 1, upload falseRestored and rebuilt afterwards; the restored build passes again and
git diff --quietis clean.Non-blocking.
recordspath has no runtime test. The draw fixture binds throughoffscreen_check, not the stand-in. On the stand-in side onlycheck_udsrc()'s source assertions cover it, so a wrong argument order at anindirect_buffer_viewcall site still passes. The same holds for thecompute_root_srv_bufferfix, which is a real behaviour change:uploadused to be false on that path. A CPU-side check ofindirect_table_bufferorcompute_root_srv_buffer, or an indirect-draw case throughd3d12_xs_shim, would pin it.run_startup_raw_bufferandcheck_startup_raw_bufferaccept up to 64 entry constants. With the descriptor table that is 65 DWORDs, over the 64-DWORD root-signature limit. The fixture itself uses far fewer.551708c4. It also says the stand-in "does not yet publishnumrecords", but this head does.Verdict: approve on
587a3dec. This supersedes my changes-requested review on327d134c. R0Y00's changes request on551708c4still needs its own sign-off, so I'm not merging.Environment: NVIDIA GeForce RTX 5090 driver 32.0.16.1088, Windows 11 25H2 build 26200.9974; MSVC 19.52.37029; SDK 10.0.28000.0 DXC and FXC (the ones CTest picked up); Python 3.12.10; D3D12 debug layer on in
startup_flat_param_hardware.CI:
Build and test on Windowspasses on587a3dec;Run platform-independent Python checks on Linuxpasses too, so theg++path builds there.This reply was AI-assisted.
@pigalot on GitHub · 2026-11-27 23:29 UTC · original · approved these changes
Correction: the changes-requested review at 23:28 on
587a3decwas posted by mistake. It is a second copy of the 23:23 approval, sent with the wrong state, so please disregard it. The verdict on587a3decis approve, as written in the 23:23 review.A second, independent run over
main9345c21fagrees with that review:ps_raw_descriptortests and their neighbours (indirect, root-SRV and compute dispatch) pass in Debug and Release, on WARP and on hardware, with no skips.startup_compute_dispatch_native_*fails with "left ['revision.txt'] in the cache", and it fails the same way onmainfad97f47.recordsand the upload flag at any of the threeindirect_table_buffercall sites survives every test. A stand-in case whereNUM_RECORDSis not 1 would pin it.R0Y00's changes request on
551708c4still needs its own sign-off, so this isn't being merged from here.This reply was AI-assisted.
@SimSalabimse on GitHub · 2026-11-27 23:29 UTC · original
Thanks for the reviews, all three points are fixed on
327d134c.@R0Y00, overflow and numrecords
The draw stand-in now keeps a numrecords constant. It reads that count from dword 2 of the table descriptor, and an unknown udsrc line refuses the translation instead of dropping every line after it. The bounded pixel load also checks each address term for overflow before the range compare, so a vgpr of 0xfffffffc plus 12, 28 or 32 stays zero instead of wrapping into the buffer.
I ran python3 -B tests/startup_gfx2hlsl_ps_raw_descriptor_check.py. Mutants that drop the overflow check, the numrecords kind, or the record-count store each fail, and the restored check passes. python3 -B tests/startup_tools_lint_check.py tools/startup exited 0. The Linux Python suite from the CI list, python3 -B tools/run_checks_parallel.py --from-dir tests/checks/python-linux plus the listed scripts, passed 246 checks and exited 0.
@tedin7, typed buffer load
A typed tbuffer load through the converted descriptor is refused again, with the same message as before this change. The control is one float load at offset 32, the first word past the record count times the stride. A mutant that lets that load through fails the check, because the shader translates with no bound.
I ran python3 -B tests/startup_gfx2hlsl_ps_raw_descriptor_check.py, python3 -B tests/startup_tools_lint_check.py tools/startup (exit 0), and the Linux Python suite python3 -B tools/run_checks_parallel.py --from-dir tests/checks/python-linux plus the listed scripts (246 checks, exit 0).
@rasptum, runtime bound and extra controls
The runtime parser knows numrecords now and fills it from dword 2 of the table descriptor, the same place stride comes from. An unknown kind or a gap refuses the manifest, so a later udsrc line is not dropped. The check covers a dwordx2 and a dwordx4 that cross the limit, stride 0, a non-zero soffset, and a conversion that runs on an s_mov copy. The old in-place control is renamed to a word overwritten with zero. Extra refusals cover a wrong stride mask, OOB select 2, a constant scale, steps out of order, and a stride taken from a second descriptor. Unaligned addresses, the swizzle bits, ADD_TID and the format field stay unchecked; that is noted in the experiment writeup.
Each of those new checks failed when I took out only its fix, then passed again after restoring it. python3 -B tests/startup_gfx2hlsl_ps_raw_descriptor_check.py passes. python3 -B tests/startup_tools_lint_check.py tools/startup exited 0. The Linux Python suite, python3 -B tools/run_checks_parallel.py --from-dir tests/checks/python-linux plus the listed scripts, passed 246 checks and exited 0.
Windows test PC: at
587a3dec, the ps_raw_descriptor tests passed twice (4/4, ctest exit 0) and startup_gfx2hlsl_ 389/389 passed, ctest exit 0.AI-Assisted
@pigalot on GitHub · 2026-11-28 03:16 UTC · original · approved these changes
Retested
130d32cb, your merge ofmain7fcde81f, integrated over currentmainfdb6faaa. The merge is clean (treed7bf28d8) andgit diff --cached --checkis clean.Your merge.
git show --remerge-diff 130d32cbshows one conflict, insrc/startup_stubs/d3d12_draw.inl, onTranslation. It keeps this branch'sUdKindenum, whose values are tied to theudsrc_*constants and includenum_records, together withmain'sSrvcomment that adds kind 5 (cube) from #2938. That is the right combination. Apart from that hunk, the PR's diff overmainis byte-identical to587a3dec's diff over its own base. So the earlier review of587a3dec, including the traced behaviour and the mutants, still applies to this code.What I ran.
Builds: full
devandrelease/O2.The PR's tests:
9/9 pass in Debug and in Release, with no skips.
startup_flat_param_hardwarereportsdebug_errors=0 debug_warnings=0for every case.Full suite:
ctest --test-dir out/build/dev --no-tests=error -j 8 -E '(startup_audio|_hardware$)'gives 2002 tests: 1945 pass, 0 fail, 57 capability skips.Still open (non-blocking, unchanged since
587a3dec).recordspath has no runtime test. A wrong argument order at anindirect_buffer_viewcall site still passes.551708c4as the commit under test.Verdict: approve on
130d32cb. R0Y00's changes-requested review on551708c4still needs R0Y00's own sign-off, so I'm not merging.Environment: NVIDIA GeForce RTX 5090 driver 32.0.16.1088; Windows 11 25H2 build 26200.9974; MSVC 19.52.37029; SDK 10.0.28000.0 DXC and FXC (the ones CTest picked up); Python 3.12.10; D3D12 debug layer on in
startup_flat_param_hardware.This reply was AI-assisted.
@R0Y00 on GitHub · 2026-11-28 04:16 UTC · original
I tested a local reconciliation of
130d32cbwith mainfbef6381(tree10cb6814). The published head still conflicts ind3d12_draw.inl. Keep both the snapshot option and the namedindirect_buffer_viewconstructor. The constructor needs bothrecordsandsource; the former carries the pixel NUM_RECORDS value and the latter carries main's slot-67 snapshot source. The normal, null and recycled snapshot returns all use the named constructor so the fields stay in the proper slots.Release /O2 passed 6/6 with no skips: the parser, raw descriptor controls, WARP and physical pixel readbacks, and both adjacent Compute input snapshot fixtures.
Windows 11 26200.9974, inbox WARP 10.0.26100.9818 and RTX 4060 Laptop driver 32.0.16.1656. The source-built readbacks cover the first word past the converted range and the named refusal controls. Please refresh this source with current main before the hosted checks rerun.
@SimSalabimse on GitHub · 2026-11-28 06:25 UTC · original
Merged current main (only d3d12_draw.inl conflicted; kept the cube comment and the num_records enumerator) and retested
130d32cbon Windows: startup_gfx2hlsl_ps_raw_descriptor 4/4 passed, twice. No startup_udsrc test exists in this tree.AI-Assisted
@JohnConnorNPC on GitHub · 2026-11-28 07:34 UTC · original
Thanks for the fixes on
130d32cb. I re-checked that head against mainc3204a9c. The translator side looks sound, but two items still need a change before this can merge.Must fix
5033d2d3):git merge-tree --write-tree c3204a9c 130d32cb→ rc=1, 2 hunks insrc/startup_stubs/d3d12_draw.inl. Main addedint sourceafterupload, so the merged struct readsstride, records, upload, source. Two returns merge cleanly but fill the wrong fields:return {zero_ring, zero_offset, 16, 0, true, 3};andreturn {ring, ring_offset, bytes, stride, true, 2};(truelands inrecords, the source value inupload). The check'sudsrctext asserts don't cover those lines, so it stays green either way. Please use the resolution from R0Y00's 04:16 comment, where every return goes through the namedindirect_buffer_viewconstructor with bothrecordsandsource. Then push so CI reruns.indirect_table_bufferand the slot-18 branch ofdraw_translated) setstride/strides[i]but neverrecords/record_counts[i].git show 130d32cb:src/startup_stubs/d3d12_draw.inl | grep -n 'record_counts\[i\] = 'finds only theview.recordsandwords[2]lines. As a result,{ uint lim = ud3 * ud4;is 0, and every converted pixel load from such a view reads 0 without a log line. On main, the translator refuses a load through a modified descriptor. I found this by reading the code and did not run it. Please set the record count from the view'sNumElements, or refuse anumrecordsconstant on a token SRV.Should fix
3. The wrap guard is never drawn.
check_drawdraws onlyprogram(conversion())(v0=0). Thev0=0xfffffffcprogram is checked as HLSL text and throughraw_dwords, which is the check's own model. Drawing it as well would show the expected0,0,0,0on a real device.4. The manifest-loader refusal is unpinned. Mutant: change
return;tocontinue;afterx2w-draw unsupported udsrc→ the check still passes, because it asserts only the log string. A regression through the loader, as R0Y00 asked, would catch this.5. A stale bound is unpinned. Mutant: drop
self.raw_load_bound = Noneintools/startup/gfx2hlsl.py→ the check still passes. With two descriptors, the load from untouched descriptor B then picks up A's limit:v2 = (ok && a + 4u >= a && a + 4u <= lim) ? r1.Load(a + 0) : 0u;, where the original givesv2 = r1.Load(a + 0);. A two-descriptor control would pin this.Still open: Leyukaka's constant limit is unchanged (
constants.size() > 64intests/offscreen_check.cpp,constant_count > 64intests/startup_flat_param.cpp; the descriptor table costs one more DWORD). The PR body still names551708c4and says the stand-in "does not yet publishnumrecords".What I ran:
tests/startup_gfx2hlsl_ps_raw_descriptor_check.pyexits 0 at130d32cb. Each mutant ran on a copy that was restored and hash-verified afterwards. I did not build or run anything under Wine, WARP or a GPU.This comment was AI-assisted.
@pigalot on GitHub · 2026-11-28 11:11 UTC · original · approved these changes
Retested
445abdf7integrated overmainec71c290(tree7b6c6606). The trial merge is clean andgit diff --cached --checkis clean.What changed since
130d32cb.445abdf7is a merge ofmain3926a289, andgit show --remerge-diff 445abdf7shows it also carries new work beyond the conflict resolution. I read all of it:d3d12_draw.inl(R0Y00 04:16Z, JohnConnorNPC 1): resolved as asked.IndirectBufferViewis nowIndirectBufferViewOf<ID3D12Resource>in the newindirect_buffer_view.h, withstride, records, upload, source. All seven construction sites (five inindirect_table_buffer, two incompute_root_srv_buffer) go through the named constructor with bothrecordsandsource.main's snapshot option is kept; the null return passes source 3 and the snapshot return source 2. No brace-initialised return is left.view.Buffer.NumElements(recordsinindirect_table_buffer,record_counts[i]indraw_translated).check_drawnow draws thev0 = 0xfffffffcprogram and expects0,0,0,0, with DXC and FXC.x2w-draw unsupported udsrchasreturn;and nocontinue;.v2 = r1.Load(a + 0);for the untouched descriptor.What I ran. Full
devandrelease/O2builds, then13/13 and 3/3 pass in Debug and in Release, with no skips. On hardware, both compilers read back
3f800000,40800000,41000000,00000000and "a wrapping address reads four zeros".startup_flat_param_hardwarereportsdebug_errors=0 debug_warnings=0for every case.Negative control and mutants. Each was rebuilt in
devand run against the sevenps_raw_descriptor,indirect_translated,slot67_indirect_dispatchandcompute_dispatch_inputtests (WARP). The unmodified tree passes 7/7.tools/startup/gfx2hlsl.pyback tomain_ps_raw_descriptorand_warpfailself.raw_load_bound = Nonereturn;→continue;sourceudsrc driver exit 9;startup_compute_dispatch_input_warpalso fails)strideinrecordsudsrc driver exit 10)startup_indirect_translated_draw_warpfails at run time)startup_compute_dispatch_input_warp)records = 0;added afterrecords = view.Buffer.NumElements;record_counts[i] = 0;added afterrecord_counts[i] = view.Buffer.NumElements;record_counts[i] = view.stride;added afterrecord_counts[i] = view.records;offscreen_checkaccepts 64 constants againNo equivalent mutants. The files were restored afterwards and
git diff --quietis clean.Non-blocking.
587a3dec, now narrower: the constructor and the argument order are covered, the value that reachesud<numrecords>in a stand-in draw is not. A stand-in draw through a converted descriptor withNUM_RECORDSother than the stride would pin it.stride 0andbytes = NumElements * 4, and nowrecords = NumElements. The table-descriptor branch treats stride 0 as one byte per record (bytes = (stride ? stride : 1) * words[2]). With the clamped conversion the shader's limit ismax(0, 1) * NumElements, a quarter of the view, so loads from the upper three quarters would read 0. With the plain conversion the limit is 0. Suggested direction, unconfirmed: publishbytesas the count when the view is raw, or refuse anumrecordsconstant on a raw token view.551708c4as the commit under test and says the stand-in "does not yet publishnumrecords". The fixes for the latest review are inside a commit titled as a merge ofmain; a line in the description listing them would help the next reader.Verdict: approve on
445abdf7. The findings from my earlier reviews and the ones from R0Y00's 04:16Z comment and JohnConnorNPC's 07:34Z comment are addressed at this head as listed above. R0Y00's changes-requested review on551708c4is still recorded and needs R0Y00's own sign-off, so I am not merging this.Environment: NVIDIA GeForce RTX 5090 driver 32.0.16.1088; Windows 11 25H2 build 26200.9974; MSVC 19.52.37029; Python 3.12.10; D3D12 debug layer on for the hardware runs (
X2W_TEST_DEBUG_LAYER=1).CI:
Build and test on Windowspasses on445abdf7.This reply was AI-assisted.
@SimSalabimse on GitHub · 2026-11-28 11:18 UTC · original
The five review items are fixed on
445abdf7, which merges main3926a289.IndirectBufferViewreturn goes through the namedindirect_buffer_viewconstructor with bothrecordsandsource, as in the 04:16 resolution. The check asserts those exact return lines (and that the old brace-init returns are gone), so a swapped field fails.startup_udsrc_line_checkalso builds three views and checks the fields.recordsfrom the view'sNumElements.v0=0xfffffffc) is drawn as well, and the device readback is0,0,0,0.x2w-draw unsupported udsrc, the check requiresreturn;and fails if that becomescontinue;.Windows test PC (NVIDIA 32-lane), head
445abdf75fa3d0be20db11262a570478b5ad749e:startup_gfx2hlsl_ps_raw_descriptor,startup_gfx2hlsl_ps_raw_descriptor_udsrc,startup_gfx2hlsl_ps_raw_descriptor_warpandstartup_gfx2hlsl_ps_raw_descriptor_hardwarepassed twice (4/4, ctest exit 0, no skips; 4.62 s and 4.50 s).startup_compute_dispatch_input_warpandstartup_compute_dispatch_input_hardwarepassed (2/2, ctest exit 0, no skips, 11.13 s). The same worktree then ran the fullstartup_gfx2hlsl_list: 391/391 passed, 0 failed, 0 skipped, ctest exit 0, 737.60 s.AI-Assisted
445abdf75fto49a1590e7f@SimSalabimse on GitHub · 2026-11-28 22:34 UTC · original
Retested the rebased head
c0d43994on the Windows test PC (MSVC,--preset dev,-j 1).49a1590e(the first push after the rebase) did not build with MSVC:d3d12_compute_dispatch.inl(791)C2397, int to bool narrowing. The scalar-window snapshot brace put the upload flag intorecordsand the source number intoupload.c0d43994builds that view by member name and adds a check for this call.ctest -R '^startup_gfx2hlsl_ps_raw_descriptor|^startup_compute_dispatch_input_': 6/6 passed, exit 0 (udsrc, ps_raw_descriptor, warp, hardware, compute_dispatch_input warp and hardware)The only conflict with main was in
d3d12_draw.inl; the PR still has 13 files changed. @pigalot could you take another look since the approval was on the pre-rebase head?AI-Assisted
@pigalot on GitHub · 2026-11-29 07:22 UTC · original · approved these changes
Retested
c0d43994integrated overmain212d4b5f(treec576752c). The trial merge is clean andgit diff --cached --checkis clean.What changed since my approval on
445abdf7. The branch was rebased ontomain0614f68c, so I compared the PR's own diff at both heads (git diff <base>...<head>over the 13 files). Two lines differ, and nothing else:src/startup_stubs/d3d12_compute_dispatch.inl: the scalar-window snapshot thatmainadded since then,view = {chunk, start, bytes, stride, true, 2};, is nowview = indirect_buffer_view(chunk, start, bytes, stride, words[2], true, 2);. With the PR's extrarecordsmember the brace form puttrueinrecordsand2inupload(the C2397 the author reports on49a1590e). The named call keepsupload = trueandsource = 2as onmain.tests/startup_gfx2hlsl_ps_raw_descriptor_check.py: one assertion for that exact line.I also looked for any other positional initialisation of the view in the merged tree. There is none: the eight construction sites all go through
indirect_buffer_view, andnative_mesh57.inlonly reads members by name.The items from my earlier reviews, R0Y00's 04:16Z comment and JohnConnorNPC's 07:34Z comment are unchanged from
445abdf7, where I checked them one by one; the controls for them still kill their mutants below.What I ran. Full
devandrelease/O2builds, thenstartup_compute_dispatch_native_warp(77), so the scalar-window case ran on hardware only.3f800000,40800000,41000000,00000000and "a wrapping address reads four zeros";startup_flat_param_hardwarereportsdebug_errors=0 debug_warnings=0for every case.A first Release hardware attempt failed
startup_gfx2hlsl_ps_raw_descriptor_hardwarebecause my own mutation run was editing the sources that check reads at the time. With the tree untouched it passes; the 4/4 above is that rerun.Title run. prwatch's real-title run of this head merged onto the baseline commit: pass (job 12).
Negative control and mutants. Each was rebuilt in
devand run againststartup_gfx2hlsl_ps_raw_descriptor,_udsrc,_warp,startup_compute_dispatch_input_warpandstartup_compute_dispatch_native_warp(the last one skips, as above). The unmodified tree passes.tools/startup/gfx2hlsl.pyback tomain_ps_raw_descriptorand_warpfailsource2 → 0uploadtrue → falsestrideandrecordsswappedrecordswords[2]→ 0return;→continue;self.raw_load_bound = Nonesource_udsrc, andstartup_compute_dispatch_input_warpfails)records_udsrc)records = 0;added afterrecords = view.Buffer.NumElements;445abdf7)10 run: 9 killed, 1 survives. One of the killed ones is equivalent at run time and is caught by text only. The files were restored afterwards and
git diff --quietis clean.Non-blocking.
startup_compute_dispatch_native_hardwareandstartup_compute_dispatch_input_hardwareon the RTX 5090: all three still pass 2/2. So only the new source assertion tells them apart. This gap is inmain's own scalar-window fixture, not something this PR introduced. Therecordsargument at this site is not read by the compute path (views[i]copiesresource,offset,bytes,uploadandstrideonly), sowords[2]there has no effect today.445abdf7.445abdf7(read from the code, not run).551708c4as the commit under test and says the stand-in "does not yet publishnumrecords".Verdict: approve on
c0d43994. The rebase kept the reviewed change intact and the one new construction site is correct. R0Y00's changes-requested review on551708c4is still recorded; its two points (the droppednumrecordsentry and the wrap after truncation) are addressed at this head, but that review needs R0Y00's own sign-off, so I am not merging this.Environment: NVIDIA GeForce RTX 5090 driver 32.0.16.1088; Windows 11 25H2 build 26200.9974; MSVC 19.52.37029; Python 3.12.10; D3D12 debug layer on for the hardware runs (
X2W_TEST_DEBUG_LAYER=1).CI:
Build and test on Windowspasses onc0d43994.This reply was AI-assisted.
@Leyukaka on GitHub · 2026-11-29 10:52 UTC · original · requested changes
Head
c0d43994, read against main20bd1553(git merge-treeclean, treece8c6bf4). Diff and source reading only, nothing built or run.One construction site is still positional:
src/startup_stubs/native_mesh57.inl:23,view = {range.resource, range.offset, range.bytes, 0, true};.viewis an element ofstd::array<IndirectBufferView,32>(:14,:18). The line is the same on main, at this head and in the merged tree.resource, offset, bytes, stride, upload, source, sotrueisupload.IndirectBufferViewOf(stride, records, upload, source),truegoes torecordsanduploadstays false.booltounsignedis not a narrowing conversion, so this compiles.Effect, from reading the code:
native_mesh57.inl:205at this head doesif (!views[i].upload) require_state(self, views[i].resource, D3D12_RESOURCE_STATE_NON_PIXEL_SHADER_RESOURCE);. The range at:22comes fromlist_upload_range, whose pages are committed on an upload heap inGENERIC_READ(list_upload_pages.h). For a resource it does not track,require_stateissues aCOMMONtoNON_PIXEL_SHADER_RESOURCEtransition. On main the flag is true and no barrier is issued. The file is included outside any#ifdef(d3d12_xs_device.cpp:7077at this head).Fix:
view = indirect_buffer_view(range.resource, range.offset, range.bytes, 0u, 0u, true, 0);.check_udsrc()asserts construction lines ind3d12_draw.inlandd3d12_compute_dispatch.inlonly, so it does not see this file. An assertion for the line above would cover it.The approval on
c0d43994saysnative_mesh57.inlonly reads members by name; line 23 is the exception. Agit grepoversrc/startup_stubsin the merged tree for brace initializers ending in a bool finds no other one of this type (the two ind3d12_compute_dispatch.inlare the localstruct View).c0d43994c3to185b7decd0@SimSalabimse on GitHub · 2026-11-29 12:38 UTC · original
Fixed at
185b7decd0e0cb0bf359990c6a5dc6ead9e03dc7. The Mesh57 upload-range path now usesindirect_buffer_view(range.resource, range.offset, range.bytes, 0u, 0u, true, 0), souploadstays true. I added an assertion for that construction. The branch is rebased onto main77d1ba4d.Windows test PC (MSVC,
--preset dev,-j 1):ctest --preset dev --no-tests=error -j 1 -R '^(startup_gfx2hlsl_ps_raw_descriptor.*|native_fixed_mesh57_buffers_(warp|hardware))$' -E 'startup_audio_(output|pacing|provider)': 6/6 passed, exit 0 (native_fixed_mesh57_buffers_warp,native_fixed_mesh57_buffers_hardware,startup_gfx2hlsl_ps_raw_descriptor_udsrc,startup_gfx2hlsl_ps_raw_descriptor,startup_gfx2hlsl_ps_raw_descriptor_warp,startup_gfx2hlsl_ps_raw_descriptor_hardware)AI-Assisted
@Leyukaka on GitHub · 2026-11-29 12:41 UTC · original · approved these changes
Head
185b7dec, rebased onto main77d1ba4d. Diff and source reading only, nothing built or run. This replaces my review ofc0d43994.git range-diffagainstc0d43994: the six earlier commits are unchanged apart from rebase context in one of them.185b7decis new (2 files, +4/-1).Fixed:
src/startup_stubs/native_mesh57.inl:23is nowview = indirect_buffer_view(range.resource, range.offset, range.bytes, 0u, 0u, true, 0);. With the signature inindirect_buffer_view.h:21(stride, records, upload, source),uploadis true andrecordsis 0, as on main, so theif (!views[i].upload) require_state(...)loop issues no transition for the upload range.check_udsrc()now asserts that line and the absence ofview = {range.resource(tests/startup_gfx2hlsl_ps_raw_descriptor_check.py:422-424). Restoring the old line fails both. This is a source-text assertion; no test I read checks the flag at run time.No other brace initializer of
IndirectBufferViewremains undersrc/startup_stubs; the ones ind3d12_compute_dispatch.inl(:651,:839,:884,:926) are the localstruct View(:587).Not run by PR CI:
startup_gfx2hlsl_ps_raw_descriptor_(udsrc|warp|hardware)andnative_fixed_mesh57_buffers_(warp|hardware)are not in theprtest filter. The Linux job runs the Python script with the assertion above. The device tests rest on your 6/6 on185b7dec.git merge-tree --write-treeontoorigin/main77d1ba4d: clean.@JohnConnorNPC on GitHub · 2026-11-29 12:55 UTC · original
Review of
185b7dec(merge-base = main77d1ba4d). Verdict: hold. Leyukaka approved this head, so the change request that still blocks the merge is R0Y00's on551708c4, which needs R0Y00's re-review. pigalot's and my earlier points from that round look addressed. One point should be fixed before merging.SHOULD
stride = raw ? 0 : element;thenrecords = view.Buffer.NumElements;(d3d12_draw.inl:2578-2579), andstrides[i] = typed_view ? element : view.Buffer.StructureByteStride;thenrecord_counts[i] = view.Buffer.NumElements;(:3457-3458).max(ud<stride>, 1u) * ud<numrecords>(thefactor = 'max(ud%d, 1u)'line in gfx2hlsl). Per the PR's own comment, it exists because "The clamp (s_max_u32 with 1) makes a stride of 0 count as one byte per record".R32_TYPELESSraw view of N elements the limit is N bytes against 4N in the view. Loads in the upper three quarters read 0, with no log line.records = raw ? bytes : NumElements, and the same at :3458), plus a raw-view case in theudsrcdriver, would close it. The default launcher path (X2W_NATIVE_SHADERS_ONLY=1, which skips these manifests) is unaffected.-Translateruns are where it would show.CI on this head: Windows, fixtures and Linux Python pass. I didn't build or run the device tests.
AI-assisted.
@pigalot on GitHub · 2026-11-29 13:39 UTC · original · reviewed
Retested
185b7decintegrated overmain77d1ba4d(treea9cdca5f), the commit it is rebased onto. That trial merge is clean andgit diff --cached --checkis clean.This head now conflicts with
main. While I was testing,mainmoved to4b0586d4(#3400 and #3402).git merge-treereports one conflict, insrc/startup_stubs/d3d12_draw.inl:mainadded#include "startup_stubs/input_view_token.h"and fourstatic_assertlines at the place where this PR adds its two includes (udsrc_line.h,indirect_buffer_view.h). Both sides are needed.CMakeLists.txtandd3d12_compute_dispatch.inlmerge automatically. Everything below was measured over77d1ba4d, not over4b0586d4; I have not built the resolved merge.main's new commits add no newIndirectBufferViewconstruction site (git diff 77d1ba4d origin/main -- src/startup_stubs/).A correction to my review of
c0d43994. There I wrote thatnative_mesh57.inl"only reads members by name" and that every construction site went throughindirect_buffer_view. That was wrong: line 23 was stillview = {range.resource, range.offset, range.bytes, 0, true};, which with the newrecordsmember puttrueinrecordsand leftuploadfalse. Leyukaka found it; my approval ofc0d43994should not have been given with that line in place.What changed since
c0d43994.git range-diffover the two bases: the six earlier commits are the same apart from rebase context in one hunk ofd3d12_draw.inl.185b7decis new, two files:native_mesh57.inl:23is nowview = indirect_buffer_view(range.resource, range.offset, range.bytes, 0u, 0u, true, 0);. Against the signature inindirect_buffer_view.h(stride, records, upload, source) that givesupload = true,records = 0,source = 0, which is whatmainhas. The loop at:202(if (!views[i].upload) require_state(...)) therefore skips the upload range again.check_udsrc()asserts that line and thatview = {range.resourceis gone.I searched the merged tree again for brace initialisation of the view type, this time by pattern over all three files that use it (
view = {,typed = {,views[...] = {,return {,IndirectBufferView{...}). The nine construction sites all callindirect_buffer_view. The remaining brace assignments are other types: the localstruct Viewind3d12_compute_dispatch.inland the index-buffer view atd3d12_draw.inl:3706.What I ran. Full
devandrelease/O2builds over77d1ba4d, thenstartup_compute_dispatch_native_warp(77).3f800000,40800000,41000000,00000000and "a wrapping address reads four zeros";startup_flat_param_hardwarereportsdebug_errors=0 debug_warnings=0for every case.Title run. prwatch's real-title run of this head: pass (job 35).
Negative control and mutants. Each was rebuilt in
devand run againststartup_gfx2hlsl_ps_raw_descriptor,_udsrc,_warp,native_fixed_mesh57_buffers_warpandstartup_compute_dispatch_input_warp. The Mesh57 mutants and "constructor dropsupload" were also run againstnative_fixed_mesh57_buffers_hardwarewith the debug layer on. The unmodified tree passes all of them.tools/startup/gfx2hlsl.pyback tomain_ps_raw_descriptorand_warpfail ("through a modified descriptor")uploadtrue→falserecords0u→1unative_mesh57.inlreadsrecords)source2 → 0records_udsrcand the source assertion)upload_udsrcand the source assertion);native_fixed_mesh57_buffers_hardwarepassesrecords = 0;added afterrecords = view.Buffer.NumElements;445abdf7andc0d43994)8 run: 7 killed, 1 survives. One of the killed ones is equivalent at run time. The files were restored afterwards and
git diff --quietis clean.Non-blocking.
uploadfalse on that line,native_fixed_mesh57_buffers_warpandnative_fixed_mesh57_buffers_hardware(RTX 5090, debug layer on) still pass. So the device tests would not have caught the regression atc0d43994, and would not catch it coming back in a different spelling. I did not check whether the fixture's root SRV address is inside an upload range at all; if it is not, the changed line is never reached by a test. That gap is inmain's Mesh57 fixture, not introduced here.551708c4as the commit under test and says the stand-in "does not yet publishnumrecords".Verdict: comment, not an approval, because the head no longer merges into
main. Over77d1ba4dI found nothing blocking: the Mesh57 site is fixed and the rest is unchanged from what I tested before. Please mergemain4b0586d4(keep both include blocks ind3d12_draw.inl); I will retest that head. R0Y00's changes-requested review on551708c4is still recorded; its two points (the droppednumrecordsentry and the wrap after truncation) are addressed at this head. I am not merging this.Environment: NVIDIA GeForce RTX 5090 driver 32.0.16.1088; Windows 11 25H2 build 26200.9974; MSVC 19.52.37029; Python 3.12.10; D3D12 debug layer on for the hardware runs (
X2W_TEST_DEBUG_LAYER=1).CI:
Build and test on Windowspasses on185b7dec.This reply was AI-assisted.
@Leyukaka on GitHub · 2026-12-01 16:14 UTC · original
Taking this over since there has been no activity for 48 h; will hand back if you resume. Your commits stay as they are and keep your authorship; I will rebase onto current
main, address the open review points and report the test results here.View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.