Repository navigation
Tools: distinguish InnerCoverage metadata absence from unknown - #4498
Conversation
|
Tested
No GPU, no game data. AI-assisted. |
Kam471
left a comment
There was a problem hiding this comment.
Ran this at d6575273 on Windows 11: python -I tests/test_inner_coverage_metadata.py -> 3 tests, OK; git diff --check clean.
The feature scan now distinguishes InnerCoverage metadata absence from an unknown value, and the synthetic cases cover both. No blocking issue.
Flyander
left a comment
There was a problem hiding this comment.
The implementation preserves the two independent metadata signals and classifies missing or truncated chunks as unknown. I checked the DXC definitions: InnerCoverage is feature bit 0x400 and system value 70 is NotInSig for pixel-shader input, so the warning against treating ISG1 absence as non-use is accurate. Counts-only output and the malformed-signature bounds checks are covered by the added synthetic tests.
|
Tested
AI-assisted (Devin). |
|
Tested d657527 merged with main 03b09a0 (already up to date) on Linux (WSL2) Python 3.12.16 and native Windows 11 Python 3.13.1: pass.
|
|
Verified d657527 merged with main 3faac55: merge clean; the new tests/test_inner_coverage_metadata.py is green under python -I (class correctly above unittest.main(), re-run) and the five feature_scan neighbours plus the newline guard are unaffected. The SFI0/ISG1 cross-tab keeps missing/truncated metadata as unknown rather than absent, all reads are bounds-checked before use, and the 0x400/70 constants carry their spec citations. Checks pending. AI-assisted: yes. Tested on Linux (RTX 5080 host, CPU-only run). |
Problem and behavior
feature_scan.pyalready counts the SFI0 InnerCoverage feature bit, but that total alone does not distinguish an unset bit from missing or truncated metadata, or explain its relationship to the input signature. A missing ISG1 entry must not be interpreted as proof that a shader does not use InnerCoverage.Add a per-stage cross-tabulation of independent observations:
set,clear, orunknownfor feature bit0x400.present,absent, orunknownfor system value70.unknown; unreadable containers retain the existing unreadable count.The additive JSON field is
dxbc.inner_coverage_metadata; the CLI prints the same aggregate counts with an explicit interpretation warning. No shader names or contents are added to the output.Contract and scope
DXC defines the feature bit and signature system value separately. The DXIL semantic interpretation table classifies InnerCoverage as
NotInSig. This is why a set feature bit and an absent signature entry are retained as independent observations.This is metadata research tooling, not an Xbox FSSM/VGPR mapping or a runtime capability change. It does not establish feature non-use in a real shader collection. No real-corpus measurement is claimed; every test input is constructed synthetically.
Claim: #4421 (comment)
Related research: #4290. This PR is independently based on main
03b09a086592a197db64d91655c6e65c30764d96and does not depend on #4290, #3970 or #3451.Validation
Windows, Python standard library; no GPU required. All passed:
python -I tests/test_inner_coverage_metadata.py(3 tests, including the set/clear/signature matrix, truncated/missing metadata and end-to-end counts-only CLI/JSON output).python -I tests/test_feature_scan.pypython -I tests/test_feature_scan_bad_index.pypython -I tests/test_feature_scan_order.pypython -I tests/test_text_write_line_endings.pypython -I tests/test_text_encoding.pygit diff --check