Tested merge candidate: open PRs added a batch at a time, each batch built, tested and run on the title (replaces #3327) #3409
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3409"
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 Marvisak/VIctory. Originally posted by pes7 on 2026-11-26T22:51:23Z.
Draft, a tested merge candidate.
mainplus 53 open pull requests, added a few at a time. Each step was checked by building, testing and running the title, so maintainers can see which PRs are known to work together and with the title. It replaces #3327, which is closed (see below for why).Nothing here closes or replaces any of these pull requests: each stays open and is closed only when it lands in
main. If it helps, merging this branch lands them all at once with the checks below already done. Picking single PRs from the list is just as fine.Why a smaller tested set, not everything that is green
In #3327 I merged every open PR that merged cleanly and had a green
check, 375 of them. That set builds and passescargo test, but it does not run the title. Each problem below was found by bisecting that set or by others' reports:0x887A0004) about 70-90 s in, at the first cutscene, on a machine with three adapters. One cause found in the set was #967 (the adapter choice); other combinations still did it after #967 was reverted.xmem/ guard PRs. #2848's guard-reopen commit was one of them, confirmed independently in #2848 by @Jackster and since removed from it.lower.rsgrowing past the 512 KiB asset policy once enough shader PRs are combined.So "mergeable and green" alone is not enough: individually fine PRs break the title in combination. This branch therefore grows only by steps that keep the title running.
How each PR got in
PRs taken, most useful first:
merge-candidateon their current head;They were added in batches (six at first; later rounds larger, halved on failure). Since the device-removal fix, every new state also gets three title runs, with the D3D12 debug layer on. A batch stays only if all of these hold:
cargo check --workspace --all-targets --lockedcargo test --workspace --locked: 0 failures (the one known flakyrelaunch_closes_its_duplicated_process_handleis ignored)diagnostics, Series X, a scriptedEnter/ hold schedule through #3392, warm shader cache), judged automatically, with screenshots every 30 s also looked at:device removed;A batch that fails is halved until the PR that fails it is out. That PR is listed with the reason.
The base,
main+ #3392 alone, reaches the prison yard in 300 s with 10 552 draws a frame. #3392 is in the base only because the scripted input needs a held key.In this branch (53)
Batch 1, title OK (max 10132 draws a frame):
Batch 2, title OK (max 11200 draws a frame):
Batch 3, title OK (max 10581 draws a frame):
Batch 4, title OK (max 11409 draws a frame):
Batch 5, title OK (max 10827 draws a frame):
Batch 6, title OK (max 10317 draws a frame):
Batch 7, title OK (max 10578 draws a frame):
Batch 8, title OK (max 10473 draws a frame):
Batch 9, title OK (max 11812 draws a frame):
Batch 10, title OK (max 11017 draws a frame):
A fix on top: #3540 (an invalid raw SRV removed the device)
After the batches from #2472 to #1701, the title removed the device in 3 of 4 runs, about 200 s in. #2472 + #3035 had also needed a second run. Each time it was
DXGI_ERROR_INVALID_CALL. WithVICTORY_D3D12_DEBUG=1the debug layer named the call:CreateShaderResourceViewof a raw view withFirstElement (2). The host wants raw views to start on 16 bytes; the console takes any dword.This is in
main(buffer_srv), not in any of the PRs here. The PRs only change which host copies exist, so the faulting view came up more often. #3540 makes raw views (SRV, UAV and constant buffers) take a copy that starts on 16 bytes. It is merged here as its own commit.With it, the same set: 3 of 3 title runs with no device removal and no raw-view message from the debug layer;
cargo test --workspace930 passed, 0 failed;clippy -D warningsclean, also with--all-features.Merges adapted here, not in the PRs
#450 changes
Host::rtvto takeOption<&ID3D12Resource>. Tests written againstmainstop compiling next to it: #2962's (1e25b23), and #2729's and #642's (965d938). These commits change only those test calls,&xtoSome(&x).Tried and left out
Conflict with the set so far (need a rebase onto it, not judged)
#2821, #2542, #2727, #3065
Status
victory-shader(about 140), in the same way, as the machine is free for title runs. This branch is pushed only at points where the title run passed. A failing run is repeated before a PR is left out, since a device removal can come and go.Known and open: in about one run in three, the cutscene picture stays black for about 60 s (roughly 120-180 s in) while the subtitles keep going, and then the world appears normally. It happened on an earlier state of this branch too, so it does not come from the latest additions. The cause is not known yet, and I have not compared it with
mainalone.Not checked: other GPUs (the batch runs are on one machine's integrated AMD Radeon; NVIDIA reruns pending) and Series S mode. The tests ran on the same machine's GPU.
🤖 Generated with Claude Code
Imported from Marvisak/VIctory. Originally posted by Jackster on 2026-11-26T23:40:51Z.
Windows 11,
63bcca4+ this PR, the CI job's three commands:cargo clippy --workspace --all-targets --locked -- -D warnings: clean.cargo test --workspace --locked: 908 passed / 0 failed across 30 suites (unpatched63bcca4here: 872;victory-gpualone goes 232 → 261 tests).cargo clippy --workspace --all-targets --all-features --locked -- -D warnings: FAILS:A test call site still passes
&texturewherertvnow takesOption<&ID3D12Resource>— one of the batches rolled up here changed that signature without its caller. So the diagnostics build does not compile; the default build and the whole test suite do.Synthetic only. AI-assisted.
Imported from Marvisak/VIctory. Originally posted by pes7 on 2026-11-27T00:52:32Z.
@Jackster thanks, that's exactly it. #2962's diagnostics-only test still called
rtv(&texture, ..)after #450 changed it to takeOption<&ID3D12Resource>, and my batch checks did not build--all-features. Fixed in1e25b23on top of the set, and CI is green on that head. On it, locally: clippy-D warningsclean both ways,cargo test --workspace908 / 0, andvictory-gpu --all-features278 / 0. The--all-featurescheck is now part of every batch.Imported from Marvisak/VIctory. Originally posted by futurepro62 on 2026-11-27T07:47:00Z.
NVIDIA full-suite run, to go with the reports above by Jackster, since none of them names a GPU run. Tested exact head
1e25b23(on its base63bcca4).Tested
dxil.dllfrom Windows SDK 10.0.26100 (the loader's default), debug.cargo build --workspace --locked, thencargo test --workspace --locked --no-fail-fast -- --test-threads=4 --skip emit::memory_tests::heap_direct_texture_reads_mark_their_heap_index --skip descriptor::host::tests::dynamic_slots_are_held_until_released --skip memory::tests::lists_share_a_table_and_copies_keep_their_views --skip emit::stride_tests::a_heap_buffer_read_by_element_takes_the_views_stride --skip emit::stride_tests::a_heap_buffer_read_where_no_buffer_view_is_reads_zeros --skip emit::synthetic_tests::gathers_at_a_level_match_the_hardware: 902 passed, 0 failed, 10 ignored.default_dir_ignores_empty_user_env_vars,empty_victory_log_falls_back_to_rust_log_and_default,constant_views_fit_their_records,views_at_new_addresses_add_no_entries,released_entries_keep_their_generations_below_the_kind_bits,views_held_whole_are_current_for_heap_syncs,null_rtv_and_dsv_descs_match_resource_dimension_and_msaa,typed_buffer_views_take_only_formats_the_device_buffers_take,buffer_views_take_a_format_the_host_takes,live_dynamic_slots_keep_a_texture_given_up,heap_syncs_make_the_slots_whose_records_hold_their_views_whole,promoted_typeless_textures_accept_null_and_unknown_format_views,a_lost_host_state_matches_no_wanted_heaps,only_a_root_descriptors_dword_four_is_a_view_offset,a_failed_save_leaves_its_changes_to_the_next,first_use_of_a_finished_pipeline_is_recorded_without_queueing,half_midpoints_round_to_the_even_neighbour,half_nan_attributes_remain_nan,a_missing_resource_has_no_default_view_format,depth_and_stencil_planes_reach_the_guest_buffer,a_format_without_unordered_access_loses_the_flag,a_declared_copy_back_after_a_marked_one_keeps_newer_title_writes,a_parent_is_found_past_many_children,registered_buffers_widen_the_search,loose_windows_are_reused_for_ranges_inside_them,overlapping_windows_agree_through_title_memory,window_sizes_are_any_power_of_two,loose_memory_must_be_committed,last_bc4_mip_ends_after_the_active_block,float_depth_rounds_at_each_u16_threshold,free_memory_is_not_tracked,a_null_or_empty_path_opens_the_key_itself,nowhere_to_put_the_key_is_an_invalid_parameter,accepts_tls_directory_ending_at_the_image_end,rejects_tls_directory_running_past_the_image_end,rejects_tls_directory_running_past_the_rva_range.typed_null_rtv_keeps_the_next_color_slot,packed_10_bit_frames_are_sampled_for_black_detection,present_without_a_plane_drains_the_draw_traceonly build with thediagnosticsfeature, so the run above doesn't include them; they pass incargo test -p victory-core -p victory-gpu -p victory-hle -p victory-loader -p victory-shader -p victory --lib --locked --features victory-core/diagnostics,victory-gpu/diagnostics,victory-hle/diagnostics,victory-loader/diagnostics,victory-shader/diagnostics,victory/diagnostics(same skips).--skipleaves out tests that fail on main63bcca4on this card too, not because of this PR:heap_direct_texture_reads_mark_their_heap_indexends thevictory-shadertest process with0xc0000005(#2571), so without the skip the rest of that crate never reports;dynamic_slots_are_held_until_released,lists_share_a_table_and_copies_keep_their_viewsand the twostride_testshit the 1,000,000-view heap cap of NVIDIA drivers (#1835, #2317);gathers_at_a_level_match_the_hardwarefails on lane 0 (#1744).Not tested
AI use
Imported from Marvisak/VIctory. Originally posted by borosf on 2026-11-27T11:48:37Z.
A data point for a tested set, from the other direction: I stacked all 20 of my open PRs onto
main(63bcca43) and onto + #2958, and ran the title. They hold together, and there is exactly one trivial conflict between them.Build and tests. 16 of the 20 merge cleanly on
main. The four that do not are conflicts between my own PRs, and all four are mechanical:gpu/src/memory.rsUSES.fetch_addand the allocation-freeget_mut; the diagnostics map update stays behind#[cfg(feature = "diagnostics")]gpu/src/copystat.rsCOUNTERS= 65 (61 +RefreshCalls+Calls/CallUs/CallWaitUs)gpu/src/memory.rsby_bit+untrackedboth keptOn top of that, #2958 conflicts in one line —
emit/lower.rs, two module declarations at the same spot (mod stride_record;from #3214-era work andmod marks;from #2958). Keeping both is the whole resolution; nothing about the marks lowering has to change.Verification of the stack (Intel Arc B580, diag profile,
--console series-x, 205 s with the title):cargo test -p victory-gpu --lib: 243 passed, 2 failed, and those same two fail on unmodifiedmainon this host (dynamic_slots_are_held_until_released,lists_share_a_table_and_copies_keep_their_views— both want a heap reachingHEAP_VIEWS, which this card caps).cargo xtask policy: 194 files ok.mainremoves the device in 1–3 runs of 4 (see #2671), so the set does not make that worse — with only one run each, that is all I would claim from it.If it is useful for the set here, the ordering that needs no hand-resolution is: #3215-era descriptor work → #3238 → #3248 → the rest, then #2958 last. I am not asking for these to be added; this is just what it costs to try.
Imported from Marvisak/VIctory. Originally posted by liandraraiane on 2026-11-28T03:35:02Z.
Hi @pes7, I've closed my pull requests and don't want to be listed as a contributor. You may keep the code, but could you please change the author of commits
19856bc,86510ac,a2189cband9e0eaa8to a neutral identity, remove any mention of my username from them, and remove my credit from the description? Thank you.Imported from Marvisak/VIctory. Originally posted by lucaseddd on 2026-11-29T07:03:18Z.
Thanks for including #602 in batch 2. It is still current: it merges cleanly on main and CI is green. Happy to rebase it if a later batch needs it.
#3817 (the opt-in LOD, small-object cull, vehicle LOD and shadow-size switches for the loader) is also mergeable with green CI, if it fits a future batch. With the switches unset, nothing changes. Measured on a 6 GB laptop GPU: https://github.com/lucaseddd/victory-rea/pull/51
Imported from Marvisak/VIctory. Originally posted by kilolimaVI on 2026-11-29T15:14:02Z.
@pes7 since you run batches on the title: would you measure frame time on one branch?
kilolimaVI/VIctoryintegration/perf-1(71dc223) is main + the eleven shader PRs fromintegration/shader-11(220 → 7 translation refusals per fiestorra's census on #201) + seven performance PRs that merge cleanly together: #3139, #3470, #3247, #2993, #3538, #3527, #3303. On a Radeon 780M: victory-shader lib 361 passed, victory-gpu (diagnostics) 278 passed, rest of the workspace, both clippy configurations and the asset policy pass. Nobody has measured these on the title yet; the README puts it at about 1 s a frame.A small A/B with
VICTORY_GPU_TIMING=1, same save/scene, a minute each, would show what they are worth:63bcca4integration/perf-1with defaultsVICTORY_VRAM_COPIES=1(#2993)VICTORY_FAST_CORES=1(#3303)Average and 1% low frame time per run is enough. If one makes things worse, that is just as useful to know.
AI-assisted (Claude).
Imported from Marvisak/VIctory. Originally posted by kilolimaVI on 2026-11-29T16:48:35Z.
@pes7 if you get to measuring perf-1, there is now integration/perf-2 on my fork: perf-1 plus #3831 and #3832 (descriptor view registry without the global mutex, sharded locks, batched slot release). https://github.com/kilolimaVI/VIctory/tree/integration/perf-2
The two needed one small fix against #3139 in perf-1 (its heap sync now asks #3831's registry once instead of locking the old views table). Build, clippy and all 283 victory-gpu tests pass twice on a Radeon 780M.
For an A/B on the same scene: record once with #3833's VICTORY_INPUT_RECORD, replay with VICTORY_INPUT_REPLAY on main, perf-1 and perf-2, keep each run's stderr, then
cargo xtask frames main.log perf1.log perf2.log(#3850's tool) prints the table with a "vs first" column.AI-assisted (Claude).
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.