tests: cover DxilModule resource handles, ViewID matrix, and loop dependencies #3735
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!3735
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-3733"
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?
@Ammmae0x on GitHub · 2026-12-01 13:02 UTC · original
Ammmae0x:tests/dxil-module→main· +1548 −0 · 5 files · 1 commits · merged 2026-12-02 02:08 UTCRefs #1149
Portable C++17 unit and header-mutation tests for
src/dxil_module.h(
x2w::DxilModule), leaving the existingtests/dxil_module_invoke_*coverage untouched. Five new files only, zero edits to existing files.
What is covered (49 cases in
tests/dxil_module_check.cpp, header-onlyagainst
src):handle(): resource sorting by(cls, space, reg), static-handlededuplication, distinct spaces (
_s<space>), indexed offsets(
r.reg ? binary("add", reg, offset) : offset,%indexed<seq>,track_inputs/loop_dependenciespropagation), cbuffer props(
bytes) vscomponent + width * 256,cls == 1+4096,comparison
+32768, and all six incompatible-binding mismatchfields (
kind,width,component,bytes,count,comparison) throwing the exactstd::logic_error("incompatible DXIL binding declarations").heap_handle()(heap_used,createHandleFromHeap218 withi1 false,annotateHandlewithuav ? 4096 : 0,track_inputs/loop_dependenciesedges,annotateHandledeclaration emitted even when
resourcesis empty) andsampler_heap_handle()(i1 true, i1 false, kind 14, props 0).finish_loop_dependencies(): cyclic multi-hop%t/%p/%indexedconvergence (
(mask & ~dest).none()termination) and rasterizerbit 128 propagation into
output_dependencies.finish_compute():uav_slots > 8((min)(count, 9u)) setting the0x8000flag (8 UAV slots clear vs 9 UAV slots and a single rangewith
count = 9set),uses_wave(524288),features,validator_minor,llvm.ident = !{!0}("x2w"), and compute/gs/msproperties (
mesh_vertices,mesh_primitives).row == UINT_MAX(
-1row/first without incrementingscalars),used == 0vs!= 0, multi-word stride(out_count + 31) / 32whenout_count > 32,gs+3andms+1trailing zeros, and allfive
"invalid graphics signature"(std::runtime_error) checks.tests/cmake/dxil_module.cmakeregisters one CTest test per case plusdxil_module_alland fiveWILL_FAIL TRUEcopy mutations ofsrc/dxil_module.h(cbuffer props, UAV+4096, loop-dependency merge,UAV slot clamp, signature row 32).
tests/dxil_module_meta_check.pycompiles and runs the real C++ check with
g++ -std=c++17and killseach mutation against its control case (C++ and meta-check mutation
sets are 1:1, zero model-only mutants).
Linux verification on this host (
g++ -std=c++17):tests/dxil_module_meta_check.py:PASS: dxil_module: 49 cases, 5/5 mutations killed (g++)(49 per-case +
dxil_module_all+ 5WILL_FAILcontrols)form_coverage_check.py,docs_links_check.py(208 files / 802 links),bidi_controls_check.py(2826 files): passrun_checks_parallel.py --from-dir tests/checks/python-linux:all 90 checks passed
git diff --check: clean; merge-tree exits 0No mingw on this host, so no Windows compile check; Windows
verification (MSVC CTest
^dxil_module) is the arbiter.Windows Verification (
a070245b)git merge-tree --write-tree upstream/main HEAD->15b30782(exit 0),git diff --checkcleanpy_compile,form_coverage_check.py,docs_links_check.py(209 files, 806 links),bidi_controls_check.py(2829 files) passeddev55/55 passed (0.90s);release55/55 passed (0.75s);dxil_module_check:PASS: dxil_module: 49/49 cases passed. AI-assisted.