Repository navigation
runtime: bind native shader requests and submit fixed mesh pipelines - #3094
Conversation
|
Reviewing the runtime layer separately at |
R0Y00
left a comment
There was a problem hiding this comment.
I verified the runtime head 10b45ff5 itself (tree c0b93e371aa0a4503a575a84fabc6a77d83966f0), stacked on #3091 a48d39dc. Building startup_stream_consumer d3d12_xs_shim compile_dxil startup_manifest_retry_check and running ctest --test-dir <build> --no-tests=error -j 1 -V -R '^(startup_(native_graphics_draw|compute_dispatch_native)_(warp|hardware)|startup_manifest_retry)$' gave four Debug passes and one WARP Compute wave32 skip. Both WARP and RTX returned 16 red / 16 clear pixels with cold and hot cache, and both existing late manifest and root controls recovered after publication.
I then forced E_FAIL only at the native candidate's CreateGraphicsPipelineState call. On both adapters, the exact runtime head reproduced the missing fallback: all 32 pixels stayed clear although the same published disk pair drew 16 red / 16 clear with native disabled. The three cache files stayed byte-identical. The test used Windows 11 26200.9974, Microsoft Basic Render Driver 10.0.26100.9818 and RTX 4060 Laptop driver 32.0.16.1656, with the D3D12 debug layer enabled. Please carry that case through the runtime fix and merge review.
shader: preserve helper-lane inputs and texture dimensions on native pipelines
|
Independent Windows receipt for the stacked #3091 + #3094 runtime at Built the eight stand-in DLLs in Release in a clean worktree and ran the title for 300 s through the diagnostic launcher. Windows build 10.0.26300.10075, AMD Radeon RX 9060 XT (driver 32.0.32029.2010), D3D12 debug layer not enabled. No game files or dumps are included. Result: clean timeout at 300.03 s (exit 0, no crash, no OOM). 5998 frames presented in 281.9 s (21.3 fps overall). Two caveats keep this from being a clean regression comparison: the branch's What the counters do establish: within 300 s the title never reaches the indirect/mesh submission path (0 |
|
Follow-up: warm-cache and 18 GiB runs on the same stack ( Run 2 (warm cache, default 14 GiB): 6689 frames in 245.4 s (27.3 fps); Run 3 (18 GiB): 6721 frames in 289.4 s (23.2 fps); Interpretation: with the cache warm, the stack reaches the same loading state as the 26/11 reference (1364 textures, 10-11 pipelines) and translates 3 compute dispatches instead of 1. The mesh/indirect path is still never engaged before the BVH-builder crash: 0 |
|
Independent fixture receipt for this stacked runtime at Clean worktree, Release preset, Windows 11 build 26300 (26H2), MSVC 19.44.35228, Windows SDK/DXC 10.0.26100.0, AMD Radeon RX 9060 XT (driver 32.0.32029.2010). The D3D12 debug layer is unavailable on this host (
The fixed-mesh and first-use graphics fixtures therefore hold on this AMD adapter in Release, which the earlier title-run receipt could not show (the title never reached the mesh path before the BVH-builder crash). |
|
Independent Windows receipt for the third review path, at the current #3139 head Environment: Windows 11 26H2 build 10.0.26300.10075; MSVC 19.44.35228.0; Windows SDK/DXC 10.0.26100.0 (DXC 1.8.2502.11); WARP cmake --preset dev
cmake --build --preset dev --target compile_dxil startup_stream_consumer d3d12_xs_shim
ctest --preset dev --no-tests=error -j 1 -V -R '^startup_native_graphics_draw_(warp|hardware)$'
cmake --preset release
cmake --build --preset release --target compile_dxil startup_stream_consumer d3d12_xs_shim
ctest --preset release --no-tests=error -j 1 -V -R '^startup_native_graphics_draw_(warp|hardware)$'
Both adapters reported: The same test also controls the valid disk pair with native preparation disabled (16 red / 16 clear), a successful native candidate (16 red / 16 clear), and missing or invalid pairs (explicit refusal, 32 clear). For the injected PSO case it checks that the published manifest, This is a bounded source-built fixture receipt: I did not run the full suite or the title, and no game files or captures were used. It establishes that the existing #3139 implementation recovers the published pair on both tested adapters for the third review case; it does not establish full-game startup. |
|
At 97cde4d, Debug and Release /O2 each had 15 passes and one capability skip (77, WARP native wave32 compute). This covered the selected fixed slot-57 mesh paths, first native draw, raw pixel UAV, pixel atomics and hardware slot-67 native Dispatch. Both graphics adapters used the existing disk pair unchanged when present and recovered the correct 16 red / 16 clear pixels after late manifest and root faults with delayed disk publication. This run did not inject a later CreateGraphicsPipelineState fault after a native candidate already became ready. Windows 11 26200.9974, WARP 10.0.26100.9818, RTX 4060 Laptop driver 32.0.16.1656. The native graphics fixture enabled the D3D12 debug layer. cmake --build --preset dev --target startup_stream_consumer compile_dxil d3d12_xs_shim startup_indirect_draw_indexed
ctest --preset dev --no-tests=error --output-on-failure -j 1 -R '^(native_fixed_mesh57(_mrt|_varying|_buffers)?_(warp|hardware)|startup_(native_graphics_draw|compute_dispatch_native)_(warp|hardware)|native_pixel_(atomic|raw_uav)_(warp|hardware))$'Repeat with the release preset. Please review this head on the compiler stack. After #3091 lands, review the resulting main diff, including the first-draw overlap with #2981, and rerun required CI before merging. |
|
I reconciled the five runtime conflicts locally, retaining this PR's exact The wider Release /O2 run on the preceding tree had 35 passes, the expected WARP Compute wave32 skip, and one failure in the packed-output negative control. The final change distinguishes a genuine SRV token from a malformed UAV token, preserving the existing refusal for each. The five affected tests then all passed: ctest --test-dir out/build/release --no-tests=error --output-on-failure -j 1 -R '^(native_compute_pack_hardware|startup_compute_dispatch_output_(warp|hardware)|startup_native_graphics_draw_(warp|hardware))$'Both draw cases include the cold/warm pixel readbacks, late manifest/root failures, regular and RTV-specific PSO fallback, and unchanged published bytes. Valid raw, structured and typed UAV cases retain the exact GPU output. Windows 11 26200.9974, inbox WARP 10.0.26100.9818 and RTX 4060 Laptop 32.0.16.1656, with the D3D12 debug layer requested by the draw and pack fixtures. These are source-built tests on the local integration. #3091 still needs its published compiler refresh and current-main CI before this PR can be retargeted. |
|
A fresh local candidate now includes the approved compiler refresh Release /O2: 37 passed, 0 failed, 1 WARP capability skip in 38 selected tests. Debug: 11 passed, 0 failed, the same WARP capability skip in 12 selected tests. First-use VS/PS draw, untouched published cache files, regular and RTV PSO fallback, slot-67 cold/warm hardware readback, raw/structured/typed pack outputs and both distinct token refusals pass. The Release set also covers fixed mesh, exact-width texture outputs and root SRVs. # Release /O2
ctest --test-dir out/build/release --no-tests=error --output-on-failure -j 1 -R '^(startup_native_graphics_draw_(warp|hardware)|startup_manifest_retry|startup_compute_dispatch_(native|input|output)_(warp|hardware)|startup_compute_root_srv_dispatch_(warp|hardware)|native_compute_pack(_hardware)?|native_fixed_mesh57.*|native_wave_virtual_derivative_controls|native_image_store_exact_width_(hardware_(r|volume|rgba)|warp_sparse))$'
# Debug
ctest --test-dir out/build/dev --no-tests=error --output-on-failure -j 1 -R '^(startup_native_graphics_draw_(warp|hardware)|startup_manifest_retry|startup_compute_dispatch_(native|input|output)_(warp|hardware)|native_compute_pack(_hardware)?|native_wave_virtual_derivative_controls)$'Windows 11 26200.9974, inbox WARP 10.0.26100.9818, RTX 4060 Laptop driver 32.0.16.1656 and SDK/DXC 10.0.26100.0. The draw and pack fixtures requested the debug layer. All fixtures were source-built. The published compiler update and current-head CI remain the gates for retargeting this PR. |
|
Thanks for the reconciliation notes. I reviewed head
Non-blocking:
Environment: Linux, static review and trial merges only. I did no build, WARP or GPU run. This comment was AI-assisted. |
# Conflicts: # CMakeLists.txt # src/startup_stubs/d3d12_compute_dispatch.inl # src/startup_stubs/d3d12_draw.inl # src/startup_stubs/d3d12_xs_device.cpp # src/startup_stubs/translated_sampler_bindings.h # tests/startup_native_graphics_draw_check.py # tests/startup_stream_consumer.cpp
# Conflicts: # src/startup_stubs/d3d12_xs_device.cpp
#3091 and #3358 have landed on
main. This PR now targetsmainand retains the first-use graphics disk-cache checks from #2981.The stand-in prepares supported VS/PS pairs at first use, binds fixed vertex inputs and reviewed slot-57 mesh pipelines, and consumes frozen slot-67 requests and prepared frontend packs. A temporary graphics translation is published only after its manifest and root signature succeed. Fault cases check that the first draw stays clear and a later draw in the same process loads the disk pipeline with all three published files intact. Slot-57 cases check selected and refused views, root constants, sampler waterfalls, attachments and source-built GPU readbacks. A fixed IA fixture uses a color centered in an RGBA8 quantization bin to check exact pixels across adapters.
Windows 11 build 26200, MSVC 19.51, Windows SDK 10.0.26100.0. WARP driver 10.0.26100.9818 and NVIDIA GeForce RTX 4060 Laptop GPU driver 32.0.16.1656. The native draw fixture requested and reported the D3D12 debug layer.
At 10b45ff, Debug ran 49 tests (48 passed, 0 failed, 1 capability skip) and Release /O2 ran 14 (13 passed, 0 failed, 1 capability skip). In both configurations WARP declined the wave32 compute dispatch. Hardware passed that case. Debug also covered the main branch's signed 64-bit scalar shifts, indexed buffer alias states and compute root SRVs.
A fixed mesh fixture creates an exclusive archive directory per run. This prevents a reused Windows process ID from introducing earlier state archives into the check. Argument probes take hexadecimal pipeline keys through
X2W_ARGUMENT_INPUT_KEY,X2W_ARGUMENT_OUTPUT_KEYandX2W_ARGUMENT_INDIRECT_KEY, together withX2W_SCENE_ARGUMENT_PROBE=1andX2W_DRAW_DUMP_FRAME. The compute probes inspect the fixture's source at root table 1 byte 64 plus buffer byte 36 and its output at table byte 32.Current main verification
Tested
0cdcfd004c1a85efc4827b41f121f23934ef7ee5againstd3d0c7f6in Release/O2. Windows 11 26200.9974, MSVC 19.51, SDK 10.0.26100, app debug layer on for the graphics fixtures, in-box WARP 10.0.26100.9818 and RTX 4060 Laptop driver 616.56.34 passed, 0 failed, 0 skipped. These source-built checks cover fixed Mesh57, disk-cache and first-use failure recovery, allocator retirement on two queues, and indirect compute. The original executable's scene-color checkpoint stays tracked in #870.
At
cb81bd81d0d309b783ec86ac22b03e4491a9cfb6the runtime sources are identical to the 34-test build. The missing-DXC control now checks the exact shader key. The focused Releasestartup_native_graphics_draw_(warp|hardware)pair passed again, 2 passed with 0 skips.