build: raise MSVC warnings for the shader compiler #3794
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3794"
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 Leyukaka on 2026-12-01T22:54:48Z.
Problem
x2w_shader_compilerandcompile_dxilbuild at the default MSVC warning level in permissive mode. Shadowed locals, uninitialized aggregate members and non-conforming code in the translator are not reported, and nothing keeps a translation unit clean once it is.Change
/W4and/permissive-. Apply/WXto the ISA decoder and the vertex-ID translator when they are built into the shader compiler; other translation units can be added as they become clean. Standalone fixture builds of the same sources are unaffected.u8string()returnschar8_t.No lowering logic changes; translator output is expected to be identical, and the corpus comparison below confirms it.
Validation
Windows, MSVC,
devpreset. The CTest selection below passes on bothmain(158ef7942) and this branch (11bf403e7).Translator corpus (DXIL fingerprints and refusal reasons), produced with the same corpus script, MSVC and DXC for both commits: the TSV is byte-identical between
158ef7942and11bf403e7(same SHA-256). The corpus script istests/translator_corpus_hash.pyfrom the translator corpus PR.This touches lines also changed by #3791 (
tools/startup/compile_dxil.cpp) and #3792 (src/gfx1013_direct_compute.inl). I will rebase after whichever merges first.