upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/test/submit_frame_test.cpp
diff options
context:
space:
mode:
authorJan Trencansky <jan.trencansky@protonmail.com>2026-11-27 13:13:30 -0500
committerJan Trencansky <jan.trencansky@protonmail.com>2026-11-27 13:22:49 -0500
commitfdd58296f79ade672af11056fe5c4276ff31e886 (patch)
treebdc2fb734f34d5cead3269cf736bfab13532893d /runtime/test/submit_frame_test.cpp
parent03f1cd7f43c6f6f283a05ec354e717235cb92ef6 (diff)
d3d12: fix console heap in-place filtering and TitleMirror home.sums sync
Root-cause fixes for four audited bugs in console heap in-place filtering and TitleMirror: 1. finish_in_place() not_tsharp zeroing & record clear: Check gfx10::is_image(words) and TitleImage::not_tsharp in finish_in_place(), zeroing w[0..3] and clearing heap.records on (w[3] >> 30) slots with d.texture == Records::none (matching fix_console_slot) so non-T# overwrites of deferred slots never leak raw words into home[slot] or leave stale texture records. 2. Record-answered / batch_answers mirror write-back tracking: Call note_title_write(base, span) outside page_mirror.mutex when apply_answer() (in finish_in_place) or answered_by_record() (in fix_vsharp) returns a mirror-resolved identity target (to == base && base >= arena.size), matching vsharp_address path 6. 3. reachable_as_written() & filter_slot_locked() semantic parity: - Reject base == 0 in reachable_as_written(), check encodable() + gpu_backings + geometry.lookup, and accept bit-47 base | ~mask direct backings even when signed_vsharp_offsets() is off (matching vsharp_address:4367, 4392). Track non-sparse direct backings as Records::resolved so target_gone re-filters them if freed. - Keep O(1) permanent rejection (Records::none) only for null base, unbacked bit-47, and out-of-arena-span offsets (base < arena.size not in title_memory, aliases, or stream-pool GPU views). - For unresolvable base >= arena.size halves (not in title_memory within span, no alias, no stream-pool GPU view), null in O(1) and record Records::waiting directly without deferring so a later SlotChange::source_added still wakes and re-filters them. 4. TitleMirror single-snapshot home/sums/copy sync: Unify home, home.sums[], and filtered copy updates through a single fill_scratch_ snapshot across map() (initial aliased fill & alias handoff), make_copy(), and finish_write_back(), preserving GPU-only pieces on existing homes so A -> B -> A writes never leave stale filtered copies and avoiding duplicate guarded copies. Tests: - title_mirror_hooks_test: added make_copy_aba_staleness (make_copy, alias handoff, finish_write_back A->B->A) and updated filter_pieces_mask_and_scratch for unified single-copy initial map. - console_heap_slot_records_test: added waiting_source_added_and_tsharp_clear. - d3d12_heap_in_place_test: added deterministic finish_in_place not_tsharp zeroing and late-alias wake-up regressions. AI-assisted: Antigravity (Gemini 4 Neon).
Diffstat (limited to 'runtime/test/submit_frame_test.cpp')
0 files changed, 0 insertions, 0 deletions