Commit Graph

5744 Commits

Author SHA1 Message Date
9b66ba9c3b Docs + tests: AMD driver quirk losing the f16 keep (valu_fuzz seed 3 programme 38) 2026-11-22 06:16:31 +00:00
326e8490bb test(runtime): distinguish integer and fractional array LOD clamps
An integer image-view minimum is permitted by Vulkan and was observed on Intel. Check an effective integer minimum separately and report both view groups before returning a mismatch.
2026-11-22 07:10:00 +01:00
eaffde2993 Merge pull request #1037 from KanameS 2026-11-22 01:08:30 -05:00
21bbceabed Merge pull request #1033 from undeadhuman37 2026-11-22 01:08:29 -05:00
c171a0fa2f docs: note Resizable BAR state in descriptor_lookup_ada.md
nvidia-smi reports a 16,384 MiB BAR1 aperture, so Resizable BAR was on.
Say so, and that the ReBAR rows are absent where the benchmark skips that
placement (review on #1033).

AI-assisted
2026-11-22 09:08:28 +03:00
bd4a3aeeff Merge pull request #1030 from bobcatchris 2026-11-22 01:08:28 -05:00
bf6a2e0481 Merge pull request #1019 from Kam471 2026-11-22 01:08:24 -05:00
3d15db456b Merge pull request #1017 from Vonsek 2026-11-22 01:08:23 -05:00
075b0a312a Merge pull request #1015 from Vonsek 2026-11-22 01:08:22 -05:00
1a38b7e808 Merge pull request #1014 from whattheflop 2026-11-22 01:08:22 -05:00
a9527fd9b4 Merge pull request #1012 from nicolas 2026-11-22 01:08:21 -05:00
986b74e2dd Merge pull request #1005 from caua-an 2026-11-22 01:08:18 -05:00
f061d2b2bb Merge pull request #995 from whattheflop 2026-11-22 01:08:13 -05:00
c01e64787b Merge pull request #979 from bbareth 2026-11-22 01:08:09 -05:00
54884a5dde Merge pull request #944 from bobcatchris 2026-11-22 01:08:09 -05:00
63bb76f079 Merge pull request #820 from kapitche 2026-11-22 01:08:06 -05:00
126de88e22 Merge pull request #743 from totonii 2026-11-22 01:08:06 -05:00
998924fea8 feat(d3d12): add ExecuteIndirect CountBuffer and optional BLAS/TLAS/RayQueryKHR support 2026-11-22 03:04:35 -03:00
09cfe2e854 rpf9_names: skip Bink 2 videos whole and keep inflation inside the --limit window
scan_archive() stepped three bytes past a KB2 signature and went on looking
for zlib headers inside the video body, so a stream embedded in a video was
reported with its names and the video's bytes were counted as zero padding or
unread. It now applies rpf9_carve.py's header test (length at +4, width and
height at +0x14) and skips a plausible video whole, counted in the new
bink2_files and bink2_bytes summary keys.

The inflate loop was bounded by the file size, not by the scan window, so a
stream crossing the end of a --limit window was still reported with a stored
size larger than the span. It is bounded by the window now, as in
rpf9_carve.py.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-22 13:04:28 +07:00
6d7bb1755a Tests: shader tools honor LEONIDA_VK_DEVICE
The GPU tools picked a device with the shared ranker but never applied the
name filter the D3D12 tests have used since #861. Filter candidates through
vulkan_device_wanted in vk_device_pick.h, report a filter that matches nothing
instead of dereferencing a null device, and cover the filter cases in the
picker test. docs/testing.md no longer says the tools ignore it.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
2026-11-22 00:02:29 -06:00
9eaf37e96f Distinguish identical connected gamepads in device-ID lookup 2026-11-21 22:59:21 -07:00
d0050c98f5 docs: D3D-56 descriptor lookup numbers on RTX 4070 SUPER (Ada)
vk_descriptor_bench at dcd8ecf on Windows 11 (25H2, 26200.9974), NVIDIA
621.01: 1k/10k/100k live entries in device-local, host-visible and ReBAR
memory, median of 12 process medians with the same round order as
descriptor_lookup_apple.md. Adds a row to docs/README.md.

AI-assisted
2026-11-22 08:59:02 +03:00
f53fc3fa48 Merge upstream large-module scheduling with cache feedback 2026-11-21 22:56:39 -07:00
4407f9f8db perf(translator): share normalization in fixed-format buffer loads
Repeated normalized tbuffer loads emit the same integer quotient for every channel. Generate one helper per magnitude width without changing the dynamic format decoder.
2026-11-22 06:56:37 +01:00
01c0a56485 d3d12: accept castable formats on committed textures
Keep the creation-time castable list on the resource, reject an SRV format
that is neither the resource format nor listed, and allow listed same-size
cross-family casts such as R8G8B8A8_UINT to R32_UINT.
2026-11-21 21:56:17 -08:00
f6e0ffbe6b Merge remote-tracking branch 'origin/main' into feat/image-load-dmask 2026-11-22 02:52:03 -03:00
2fda452e09 Stream joined music records and report their source-file offsets 2026-11-21 22:51:22 -07:00
a69292882c Docs: record the Mandy character search (no unique drawable)
Mandy is a KeyLento persistent/cutscene character schedule (KeyLento/Perschars/Peds/Unique/Mandy, pack PSP_KeyLento_perschars_peds), not a unique drawable. A read-only search of the 1.0.2.1 package found no mandy/cs_mandy/ig_mandy/mp_mandy drawable or fragment in packs.rpf (144,364 streams / 9.74 GB, 24,034 models, 12,338 name records), data.rpf (28,509 / 1.41 GB), common.rpf (954 / 50 MB), levels.rpf (2,051 nested archives, first 4 MiB per stream), story000.rpf (0-4 GiB and 14 GiB regions), script/rest-of-world/audio/anim/movies/textures.

The only name hits are an iFruit billboard and a house photo prop; story000 has *_mandy.clip animation names but no drawable. Hash controls resolve cs_kenton, u_f_o_rhonda, cs_monalisa and cs_lucia; Mandy does not. The delivered mandy/ export is therefore a labelled cs_monalisa proxy. Caveats: levels prefix-bounded at 4 MiB, raw RSC8/Bink not decoded, encrypted RPF9 TOC. No game data or localized strings included.
2026-11-22 05:51:12 +00:00
87d7bf7c43 Translator: SMEM alignment, s_buffer_load NUM_RECORDS bound, signed s_load imm, raw MUBUF per-dword tail
What was wrong (tools/rdna2spirv.py):
- s_load* / s_buffer_load* added base + soffset + imm unaligned; hardware truncates each of the three to a
  multiple of 4 before adding them.
- s_buffer_load* had no bound at all and read past NUM_RECORDS.
- s_load* zero-extended a negative immediate from 32 bits (soffset 8 + imm -4 read ptr + 4 GiB + 4).
- raw buffer_load_dword* checked only the start (offset < num_records), so a dword at NR-1..NR-3 and the tail
  of a multi-dword load returned data where hardware returns 0.

Hardware evidence: AMD Radeon RX 6800 (gfx1030, driver 32.0.21045.29003), raw compute kernels, wave32 and
wave64, 155 runs, every result 0 or the stored data, wave32 = wave64 in every dword. Decisive rows:
s_buffer_load imm 0x10 with NR 18 -> 0; imm 0x13 with NR 21 -> data@0x10; soffset 0xe + imm 2 with NR 16 ->
data@0xc; x4 at 0xc with NR 21 -> data, data, 0, 0; stride 4 with NR 5: 0x10 data, 0x14 0; stride 1 with NR 17:
0x10 -> 0; base & 3 = 1 with imm 3 -> data@0. s_load soffset 8 + imm -4 -> @4, soffset 0xb + imm -1 -> @4.
buffer_load_dword at 0xf with NR 18 -> 0; x4 at 3 with NR 18 -> d0..d2 data, d3 0.

Now: off = (soff & ~3) + (imm & ~3), dword i at (base & ~3) + off + 4i. s_buffer_load dword i is 0 and not
loaded (its own selection construct + OpPhi) when off + 4i + 4 > limit, limit = NR * stride or NR (stride 0).
s_load: imm sign-extended from 21 bits, 64-bit sum, no bound. Raw (stride 0, no idxen) buffer_load: dword i
loaded iff O + 4i + 4 <= NR. Structured, idxen, stores, atomics and format loads keep their old first-byte
check (not measured).

Inferred, not measured: s_load with soffset + imm < 0 (64-bit signed sum), s_buffer_load x16 and buffer_load
x3 (same rule), an s_buffer_load immediate with bit 20 set or negative. OOB_SELECT (V# word3[29:28]) changes
vector-load results on hardware (2 probes) and is recorded in docs/design.md, not modelled.

Tests: tests/semantic SmemHardwareRuleTests (evaluator follows branches/phis), RawBufferTailBounds and
MeasuredBoundsShaders assert values and the exact addresses read; 19 fail with main's translator. New GPU
tests cs_smem_bounds, cs_smem_stride_align, cs_smem_sload_neg, cs_buf_tail (expected words derived by hand
from the model) in check.py and scripts/run_gpu_tests.py. test_heap_base_is_added_once now gives its V# a
NUM_RECORDS (it had 0, which the measured bound turns into a load of nothing).

Tested on AMD Radeon RX 6800 / Windows / driver 26.11.2 (Vulkan), on main d937b7f: run_gpu_tests 62/62 passed;
check.py 56 of 56; unittest tests/semantic 460 OK; pytest 1796 passed, 7 skipped, 1 xfailed. The three new tests
that are safe to run with main's translator fail with it on the GPU; cs_smem_sload_neg was not run with it (it
would read 4 GiB past the heap). Indexed (idxen) buffer loads keep their single selection construct.

AI-assisted.

Rebased onto main 8df277f: since 2e8101b the semantic mini interpreter raises on a PhysicalStorageBuffer access that
is not 4-byte aligned, so RawBufferTailBounds rows that load at an unaligned O now set base_low so that base + O is
aligned (the bound sees only O, so the measured O / NR pairs are kept); the base & 3 = 3 row uses offset 5 as a
stand-in for the measured offset 3. Byte-exact data at an unaligned address is no longer asserted there.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 22:49:26 -07:00
9874e9d2ba world_census: invalidate pre-fix warm-up shard totals 2026-11-22 15:48:38 +10:00
773891bdff fix: pack D16 explicit-LOD gather results
Route both four-tap gather paths through the existing binary16 conversion so explicit LOD and offsets keep the two-word result and the following register intact.
2026-11-22 06:48:05 +01:00
3be90ae8ae Docs: correct the AMD D3D-56 table geometry and host_device_local ratios
kotorvr's review found the 100k capacity difference is not insertion order
or a vendor effect: bc8e604's bounded slot relocation keeps the table at
524,288 slots, while the NVIDIA table predates it and grew to 2,097,152. The
AMD run already includes the relocation, so the item that read it as an
argument for the relocation had it backwards.

Also correct two derived figures: the wave-uniform device_local range includes
the 100k 7.618 us/1M row (4.9-7.6), and host_device_local is within 2% at 10k,
with 1k uniform_pair_ts 6% faster and uniform_tsharp_hit 41% slower, rather
than "within 1% at 10k and 100k".

Ratios recomputed from the table. Docs only.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
2026-11-21 23:47:55 -06:00
a69977e76f fix(runtime): honor minimum LOD on sampled 2D array views
A Texture2DArray SRV encodes the clamp in its image descriptor. Forward it to Vulkan so sampling keeps the requested mip and array layer.
2026-11-22 06:47:50 +01:00
502462e1c7 rdna2spirv: set constant EXEC lane bits with shift and mask, not OpBitFieldUExtract
Intel's Windows driver (UHD 770 / Xe-LP, 32.0.101.6129) evaluates OpBitFieldUExtract
of a constant that fits in 16 bits with the offset taken mod 16, so s_mov_b32
exec_lo, 0xffff ran all 32 lanes and lanes 16-31 copied the EXEC bits of lanes 0-15.
That is what broke cs_w32_permute case C and lds_fuzz w32 programs 24 and 26 there.

(K >> lane) & 1 gives the same bit on every driver. cs_exec_const.asm checks four
constant masks, three of them 16-bit, in both GPU runners.
2026-11-22 00:46:32 -05:00
66bc9413eb docs/fssm_crosscheck.md: fssm_unpack now checks the FSSM magic (review)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 06:41:17 +01:00
0412134056 Test image loads with partial component masks 2026-11-22 02:39:51 -03:00
49c6e0ed65 Docs: record Intel UHD 770 descriptor lookup timings (D3D-56) 2026-11-22 15:34:45 +10:00
ef54dfbf94 docs/world_census.md: totals from a census that counts each stream once
Re-ran world_census.py on levels.rpf (36 shards, a 1.0.2.1 copy) with the warm-up fix. Map rows,
entities and coverage are unchanged; the stream and byte totals lose the 35 shard boundaries' double
count:

- zlib streams 1,122,614 -> 1,117,857
- stored bytes 75,165,813,806 -> 74,877,281,159, now exactly the accepted stream payload in Coverage
  (an independent, interval-based measure)
- inflated bytes 175,587,890,693 -> 174,941,755,029
- rejected candidates 906 -> 840
- the "adopted continuation streams" row is gone: it counted the double count, not joins

The metadata-streams row now reads 164,914, the census's own meta total and the sum of the
CMapData-only (138,839) and other (26,075) metadata rows further down; it said 165,880.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 5b1f5c5b6e124b0fa28a6e768ef5fabd8e5fc2aa)
2026-11-22 00:33:52 -05:00
b27b92a101 Count stored rig-name hashes in animation index reports
(cherry picked from commit 9940b3f05717a8291c25efd04780b4a8ae60a489)
2026-11-22 00:33:51 -05:00
e038d28f0b Resolve meshlet draw bindings from geometry buffer pointers
(cherry picked from commit d462d3f3604ac2002bd09aa8e0442c84aaa77b8b)
2026-11-22 00:33:48 -05:00
bf3a1562df Document independent vertex counts for 311 stride outliers
(cherry picked from commit b5aec70c80e989acc6153330c97b4ebcf6efa99c)
2026-11-22 00:33:47 -05:00
86ec0fa633 Merge pull request #977 from bobcatchris 2026-11-22 00:33:22 -05:00
07402f3828 Merge pull request #973 from Vonsek 2026-11-22 00:33:21 -05:00
fca59716df Merge pull request #964 from 465d6a0eac 2026-11-22 00:33:19 -05:00
73a5a8cfc0 Merge pull request #958 from edwin042331-hue 2026-11-22 00:33:17 -05:00
77fe981bc2 Merge pull request #957 from edwin042331-hue 2026-11-22 00:33:17 -05:00
dede55fef4 Merge pull request #956 from edwin042331-hue 2026-11-22 00:33:16 -05:00
ff97c64d16 Merge pull request #955 from edwin042331-hue
# Conflicts:
#	docs/design.md
2026-11-22 00:33:16 -05:00
04dd4d5ef5 Merge pull request #954 from Claude Code 2026-11-22 00:33:15 -05:00
cd5a8c484b Merge pull request #951 from Lucy 2026-11-22 00:33:14 -05:00