Repository navigation
Conversation
…rget count (whole corpus) u32 +0x0F8 plus u32 +0x0FC equals the binding-table record count in all 26,503 FSSM blobs; +0x0FC equals the OSG1 SV_Target count in only 229 of 12,101 pixel shaders. fssm_header.binding_table() returns the pair as 'groups' and --bindings tallies the identity. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Kam471
left a comment
There was a problem hiding this comment.
Ran this at 8d0729b24 on Windows 11: pytest tests/test_fssm_header.py -q -> 45 passed, 6 subtests passed; test_docs_table_rows.py 2 OK; git diff --check clean.
fssm_header now reads FSSM +0x0FC as a binding-table group count, not a target count, over the whole corpus; the docs row was corrected with the count and the added cases cover the group-count field next to the old misuse. I cannot recount the corpus here; the synthetic test and docs validate. No blocking issue.
|
Independent Windows 11 CPU + 1.0.2.1 whole-corpus verification at exact head \8d0729b248b967cfa7b0a85f4e7bde2473beb7eb\ (Python 3.14; claim: #5156 (comment)):
AI-assisted. |
|
Independent check — PASS: |
|
Tested
|
kacper-serewis
left a comment
There was a problem hiding this comment.
AI-assisted review. Across 12,101 cached pixel shaders at 8d0729b, +0xFC equaled the number of distinct observed color destinations in only 229. The 16,306 static color exports (all compr) belong to the 3,004 shaders whose carved stems contain case-sensitive Deferred. All pixel shaders together have 29,290, and the 807 PS_DeferredTextured shaders have 4,294. Please label the 16,306 cohort explicitly when combining with #5169; a case-insensitive name filter gave 3,014 shaders, so the 2,989 raw-entry cohort needs its own predicate. OSG1 describes declared targets, while static instructions establish observed destinations.
|
Thanks @kacper-serewis. Your 229 matches mine. The 16,306-export sentence and the 2,989 / 3,004 cohorts are in section 1, which this diff does not touch (it changes only the |
16,306 is the 3,004 PS whose .dxbc stem contains case-sensitive 'Deferred'; a case-insensitive match gives 3,014 / 16,358. All 29,290 exports of all 12,101 PS are compr. Review on ItsNotRexed#5215. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Reproduced on my 1.0.2.1 work folder, and the wording is fixed in d3813da. Counts:
The section-1 sentence now names its cohort (stem, case-sensitive), gives the case-insensitive and all-PS figures, and says these are static instructions (observed destinations) while |
|
Tested
No game files. AI-assisted (Claude Code). |
|
Tested d3813da merged onto main@0656b0b20 on Windows 11, CPython 3.13 (CPU only), with my own 1.0.2.1 copy: pass.
Counts only. AI-assisted (Claude Code). |
|
Tested
AI-assisted (Claude Code). No game data. |
PROC-261. Claim: #5156 (comment)
Pairs with #5169 (which removes the older line 14 that called
+0x0FC"the exported target count"); this PR touches only the note at lines 46-48, which #5169 keeps unchanged, so the two apply in either order.What the doc said
docs/gbuffer.md:46-48: the FSSM header dword at+0x0FCholds 5 and 6 on two sampledPS_DeferredTexturedblobs but 16 and 18 on two vehicle deferred passes, so target counts must be read fromOSG1. Four blobs, no statement of what+0x0FCis.What was measured (all 26,503 FSSM blobs of 1.0.2.1)
u32 +0x0F8+u32 +0x0FCequals the number of 20-byte records in the post-code binding table (fssm_header.binding_table()) in 26,503/26,503 blobs, in every stage.+0x0FCis 2 in all 195 GS; in PS it spans 0..84.+0x0FCequals theOSG1SV_Targetcount in 229 of 12,101 pixel shaders, 40 of 3,004*Deferred*PS, 19 of 807PS_DeferredTextured(5..21 on the six-target ones, 3..20 on the five-target ones). So it is not a target count; the doc's conclusion (readOSG1) stands and now has its reason.Method and limits
os.listdir(26,503, matchesindex.json; 769 names start with.),.dxbcpaired by stem (0 missing),OSG1parsed as 32-byte elements,SV_Targetcounted by semantic name. 0 unparsedOSG1.OSG1comparison was a local script over the same files (counts only, not committed).Changes
docs/gbuffer.md: the note at 46-48 rewritten with the counts and the command.tools/fssm_header.py:binding_table()returnsgroups(the 0xF8/0xFC pair, None if the blob ends before 0x100);--bindingsprints them per file and talliesu32 0xF8 + u32 0xFC equals the record count in N/M. Docstring updated.tests/test_fssm_header.py: three tests on synthetic blobs: a genuine split, a lookalike whose header words do not add up (reported as stored, not derived), and a blob ending before 0x100.Run
python -I tools/fssm_header.py <work>/shaders/dxbc/fssm --bindings→binding tables 26503, records 5640704, tail name equals file stem 691/u32 0xF8 + u32 0xFC equals the record count in 26503/26503python -m compileall -q make_game.py tools tests;tests/test_fssm_header.py(45 OK),test_fssm_crosscheck.py,test_fssm_wave_size.py, alltests/test_docs_*.py,tests/test_text_write_line_endings.py,scripts/check_no_game_data.py: all pass.AI-assisted (Claude Code). No GPU needed. Counts only; no shader names or content.
🤖 Generated with Claude Code