Commit Graph

9534 Commits

Author SHA1 Message Date
fff970e616 Merge origin/main into carry/1346 2026-12-02 11:51:40 +01:00
895c472faa Merge pull request #3078 from MoonEyes/carry/934
awc_shorts: refuse a catalog that would overwrite an input bank (carry of #934)
2026-12-02 10:26:51 +00:00
7a8fbc8235 Merge pull request #3060 from MoonEyes/carry/693
pe_inspect: parse and validate PE export forwarders table (OLD-9768, carry of #693)
2026-12-02 10:26:33 +00:00
3a3c008228 Merge pull request #2817 from TheGeogeo/test-red-green-mutation
scripts: red_green.py --mutate checks that the tests catch the change itself (TEST-RED-GREEN-MUTATION)
2026-12-02 10:25:40 +00:00
5ec08c383f Merge pull request #2813 from TheGeogeo/d3d12-gate-memory-series
gate: memory.csv and a pile-up's numbers beside the summary (D3D12-GATE-MEMORY-SERIES)
2026-12-02 10:17:22 +00:00
7c245a359b Merge commit 'refs/pr-all/1346' into carry/1346 2026-12-02 10:59:56 +01:00
80910637f1 Merge pull request #2812 from TheGeogeo/d3d12-gate-memory-stop
gate: a memory stop ends a run before memory runs out (D3D12-GATE-MEMORY-STOP)
2026-12-02 09:49:18 +00:00
92c713e762 Merge commit 'refs/pr-all/934' into carry/934
# Conflicts:
#	tests/test_awc_shorts.py
2026-12-02 10:47:42 +01:00
8d942ae214 tests: an export RVA at the end of the export directory is not a forwarder
The directory is [begin, end), as in runtime/src/pe_loader.cpp. A mutation that made
the end inclusive survived. Reported by enlighted-agent on the carry PR.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-12-02 08:30:47 +01:00
c681cd9261 Merge main into #693: keep resources, unverified imports and system-DLL notes next to forwarders and pdata
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-12-02 08:12:56 +01:00
52e2eae670 launcher: check for updates at start and update in one click (LAUNCHER-UPDATE)
At start the launcher runs git fetch in its folder. When the clone is
behind its upstream, the Play page says how many new commits there are
and shows an Update button. Update runs this file's own --update mode:
git pull --ff-only, then a rebuild of the runtime when d3d12/ changed,
with the output streamed like the other tools.

A copy downloaded as a zip has no .git; the launcher says that updating
needs a git clone. A Settings box turns the check off.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-02 07:38:08 +01:00
0ae5a2664b Merge pull request #2986 from TheStonedGamer/precompile-all
d3d12: opt-in precompile of every known pipeline (-PrecompileAll); never-drawn pipelines stay out of the library
2026-12-02 05:13:18 +00:00
bf65aa4505 scripts: red_green.py skips a folder it cannot list, stops with the tree put back on a __pycache__ it cannot remove, and four smaller fixes (review)
drop_bytecode skips a folder it may not list (Python cannot import from it either). A __pycache__ it cannot remove is now a usage error naming it (exit 2), and any such error during a run puts the tree back on the base, where before the undone hunk stayed. --mutate-timeout must also be finite. In a mutated run, a Python test stopped while running outweighs a cargo build that was stopped. job_of says once on stderr when it has no job object. docs/testing.md: one line rewrapped.
2026-12-02 05:19:44 +01:00
673ac44a1b tests: red_green.py checks that the process a mutated run leaves behind is stopped, not only that it does not hold the run (review)
With the output in a file the run no longer waits for such a process, so only a mark it would write later shows that the job (the process group elsewhere) stopped it. drop_bytecode reads a folder's attributes only for folders.
2026-12-02 05:19:44 +01:00
5660cff104 tests: red_green.py --mutate on code that sits only in added files has nothing to undo in the files it modifies (review) 2026-12-02 05:19:44 +01:00
0ab167f754 scripts: red_green.py refuses --mutate-max below 1, a --mutate-timeout that is not above 0, and both without --mutate (review) 2026-12-02 05:19:44 +01:00
fc0ce37ac4 scripts: red_green.py reports a cargo run stopped before any test ran as timed out building, not caught (review)
A mutated cargo run that times out before its first Running line was still a build: it says nothing about the tests, so it is no longer counted as caught by timeout. A stub cargo that hangs in its build or in a test binary now covers the cargo timeout path, which no test reached before.
2026-12-02 05:19:44 +01:00
4a0aa701d0 scripts: red_green.py lists the hunks --mutate-max leaves out (review)
With more code hunks than --mutate-max, the report read as if every hunk was tried. The hunks left out are now in --json (mutations_skipped, file and line) and in the text (not tried, past --mutate-max).
2026-12-02 05:19:44 +01:00
0d2dea6c70 scripts: red_green.py tells a hunk of test code only with one rule, for the red side and for the mutations (review)
code_hunks looked only at the lines a hunk adds, so a hunk that deletes an obsolete test inside a #[cfg(test)] module was mutated and read as not caught, while the red side took it as a test hunk. Both now use test_hunk_flags: every removed or added line is test code, blank or a comment, and one at least is test code.
2026-12-02 05:19:44 +01:00
29712017c4 scripts: red_green.py starts each mutation from a commit of the green merge, reset and cleaned (review)
A put-back that applies did not prove the tree green again: a test that wrote into a tracked file changed the result of the next hunk. The green merge is now committed with the tool's identity before its tests run, and each mutation resets the tree to it and cleans it before undoing its hunk. A hunk can no longer fail to go back, so mutations_stopped and its test are gone; a test that dirties the tree now has its own.
2026-12-02 05:19:44 +01:00
312bf7c892 scripts: red_green.py stops what a mutated run leaves behind, so an orphan holding its output does not hold the run (review)
taskkill /T on a command that has already ended finds no tree: a child it left behind kept the output pipe open, the run waited for the timeout and a real caught read caught by timeout. A mutated run now writes its output to a temporary file and, on Windows, runs in a job object (kill on close) that its children join; once the command ends or times out, the job (the process group elsewhere) is stopped.
2026-12-02 05:19:44 +01:00
a7a22ff874 scripts: red_green.py removes only the work tree's own __pycache__ folders, never through a link or junction (review)
Path.rglob follows directory junctions on Windows, so a junction in the tree to an outside folder had that folder's __pycache__ deleted, and a link itself named __pycache__ made shutil.rmtree raise. The walk now skips symbolic links and every reparse point (junctions included).
2026-12-02 05:19:44 +01:00
89274bac6e scripts: red_green.py --mutate says when it stopped, why nothing was undone, and which added files it does not mutate (review)
A hunk that cannot be put back no longer drops the whole mutations section: the report and --json (mutations_stopped) name the hunk, the reason and how many hunks were not tried. With --mutate, mutations is always a list and mutations_not_run says why none was undone: nothing to undo (a test-only pull request), or no test went red then green. Files the pull request adds stay unmutated, and the report and --json (added_not_mutated) now list them. Verdicts and exit codes are unchanged.
2026-12-02 05:19:44 +01:00
745808fc3b scripts: red_green.py --mutate-timeout stops a mutated run that hangs and reports it as caught by timeout (review)
Each command of a mutated run (cargo test, one Python test file) is stopped after --mutate-timeout seconds (600) together with the processes it started (taskkill /T on Windows, the process group elsewhere): a test binary or a process a test starts would otherwise keep the output pipe open. The hunk is then 'caught by timeout', apart from 'caught'. The red and green sides have no timeout, as before.
2026-12-02 05:19:44 +01:00
de6db4b733 scripts: red_green.py removes the work tree's __pycache__ before each Python run, so no test runs stale bytecode (review)
-B only stops writing bytecode. An ignored .pyc left in the work tree (git clean keeps it) ran instead of the reverted source: red passed and an undone hunk was not caught. -X pycache_prefix would cover the unittest process only, not the processes its tests start; removing the folders covers both.
2026-12-02 05:19:44 +01:00
dc63e371ce scripts: red_green.py --mutate checks that the tests catch the change itself (TEST-RED-GREEN-MUTATION)
Verifiers remove a line of the fix by hand on nearly every test pull request to see the new test fail.
--mutate does it for each hunk of the pull request's code outside its tests (Rust and Python files it
changes; hunks taken without context, so a test changed next to the code stays out): after the green
side, it undoes that hunk alone, runs the tests again and reports it as caught (a test that went red
then green fails), not caught, does not build or does not apply, up to --mutate-max hunks (10); the
hunk is put back after each run. Python tests now run with -B: an undone change of the same size within
the same second would otherwise run the stale bytecode.
2026-12-02 05:19:44 +01:00
0e5ebd0c69 gate: the summary even when memory.csv cannot be written, the slope up to the stop (review)
`summary` wrote memory.csv before summary.json, so a memory.csv open in another program left no
summary and exit 1. A file it cannot write or remove is now said on stderr, `series` is null and
summary.json is written. The private bytes' slope counted the memory lines written while the title
ends after the stop request; it now covers the world up to the stop, as the frame rates do. New tests:
the 2 s window and the empty cells of memory.csv, its LF line ends, the slope with lines after the
stop and with fewer than 3 lines in the world, and a memory.csv that cannot be written. The census
sentence's contract is one key over the whole part WAITS reads, the ", " between its two numbers too.
The docs name every video memory line the peak counts (the swap chain made, its buffers made again,
a budget change of 256 MB or more) and when the slope and `series` are null.
2026-12-02 04:42:49 +01:00
01203fb3bf gate: a negative memory limit is off, and the poll's order tested in full (review)
A negative -StopOverBudgetSeconds stopped every run at its first video memory line: 0 s over the budget
passed a negative limit. Every limit is now off at 0 or less, with a test for each, and a line at
exactly the private limit is tested not to stop. The poll test gets a memory limit at the time limit
(memory wins), and the script text test checks the target and time limits the loop passes and that the
memory stop's sentence reaches the stop event. The docs give the poll's whole order (a STOP file and the
world time at the same check give `target`), say that `world_time_short` and `world_not_reached` are
not added to `memory_stop`, and name `memory.stop_limits`.
2026-12-02 04:42:49 +01:00
bb6ff13127 gate: no stale memory.csv, and the docs say what the series holds (review)
`write_series` returned before an older memory.csv was touched, so a folder summarized again from a log
without memory lines kept old rows beside `series: null`: it now removes that file. Two tests go through
`main()`: no memory lines writes no file, and an older file goes. The docs list the CSV header, how its
video memory and census columns are picked (the nearest line within 2 s), `reaper_queue_max_at_s` and
`waiting_objects_max`, and that the summary's video memory peak counts every video memory line, the
swap chain's too, so it can come from a line with no row in the CSV. "Not in this version" no longer
lists the time series and the VRAM and RAM peaks. The census line's fixture is the runtime's sentence
as it is now, with the reaper's bound (LEONIDA_REAPER_LIMIT) at its end; the part the parser reads did
not change.
2026-12-02 04:42:49 +01:00
eac2b61d2f gate: the world time comes before the memory stop, the commit floor tested at 20 s (review)
A run that reached -WorldSeconds at the same poll as a memory limit was reported FAIL `memory_stop`.
It is a measurement, and its memory peaks are in the summary all the same, so the supervisor now
checks the target first. The poll's order is one function, Get-StopReason, which the test takes out
of the script and puts to PowerShell 7 with synthetic polls. The commit floor's boundary is now
tested at exactly 20 s, and the docs say what `stop.memory_why` holds: the gate's whole sentence.
2026-12-02 04:42:49 +01:00
7150b7fe0c gate: memory.csv and a pile-up's numbers beside the summary (D3D12-GATE-MEMORY-SERIES)
Testers read a pile-up by its slope and by the reaper's queue, which the summary's peaks do not show. The
parser now also reads the runtime's census line written with each memory line (objects let go that wait for
their submissions, and the reaper thread's queue) and writes memory.csv beside summary.json: one row per
memory line with the private bytes, the PC's memory free and left to commit, the card's video memory budget
and in use, the shared memory in use and the two queues. The summary's memory block gets the reaper queue
at its longest and when, the most objects waiting, and the least-squares slope of the private bytes in the
world (MB a minute). The census strings join the contract test.
2026-12-02 04:42:49 +01:00
cb5bcfc205 gate: the private-bytes stop also follows the PC's memory (review)
With a large page file the commit limit is far above what a PC survives: two Windows crashes (0x10E)
came at about 100 GB private on a PC with 64 GB of memory and a 175 GB limit, where 90 % of the limit
is 158 GB. The default is now the lower of 90 % of the commit limit and 1.25 x the physical memory
(80 GB there, 36 GB here); the video memory stop stays on by default.
2026-12-02 04:42:48 +01:00
aa75f13197 gate: a memory stop ends a run before memory runs out (D3D12-GATE-MEMORY-STOP)
A memory pile-up has taken a PC's whole Windows down, not only the device, and a fixed 80 GB cap never
triggers on a PC with a 40 GB commit limit. The supervisor now asks `game_gate.py state` for a memory stop,
read from the runtime's latest memory lines: the game's private bytes past -StopPrivateMB (default 90 % of
this PC's commit limit), the PC under -StopCommitLeftMB left to commit for 20 s (default the larger of
128 MB and 0.25 % of the limit), or video memory over the system's budget for -StopOverBudgetSeconds (60).
0 turns one off. The run then stops the same clean way, with the reason `memory`; the limits go into
run.json and the summary, the limit passed into `stop.memory_why`, and the verdict is FAIL `memory_stop`.
`start` forwards the limits to the detached run.
2026-12-02 04:42:48 +01:00
4dfd90c35a Merge pull request #3024 from ProjectLeonida/batch/report-paths-consolidation
tools: batch report_paths consolidation (15 PRs by @breachato)
2026-12-02 01:03:11 +00:00
825f09d998 Merge pull request #2903 from KelboLive/tests/address-guard-basename
tests: rename the address-guard unit test so discovery stops importing two test_address_guard modules
2026-12-02 00:58:10 +00:00
4b67b07045 Merge pull request #2931 from Mykolas009/d3d12/f1-dlss-rebuild
d3d12: the DLSS build is asked for once NVIDIA's SDK is here, whatever the switches (D3D12-F1-DLSS-REBUILD)
2026-12-02 00:48:23 +00:00
535308fe48 Merge pull request #2761 from merzleckeier/fix/1080-1440p-motion-blur-switch
d3d12: preserve explicit MotionBlur values in the 1080p–1440p preset
2026-12-02 00:47:52 +00:00
c1404a69f0 Merge pull request #2998 from bobcatchris/fix/tests-disasm-partial-swizzle-encoding
TESTS-DISASM-PARTIAL-SWIZZLE-ENCODING: include gfx1013 encodings in cs_w64x_partial_swizzle disasm fixture
2026-12-02 00:47:21 +00:00
5b03c688bf Merge pull request #2966 from aznohonza/scripts/entry-point-help
scripts: --help answers in the Python and shell entry points
2026-12-02 00:47:12 +00:00
97f123dc9a Merge pull request #2905 from fiestorra/fix-conftest-finder-order
conftest: install the piecewise finder before the translator is imported
2026-12-02 00:46:09 +00:00
d8876ec0e3 tests: list text_tables in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:43 -05:00
3cc295a3c2 tests: list skin_streams in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:43 -05:00
301bec535c tests: list instance_lists in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:43 -05:00
e51ec83b37 tests: list anim_clips in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:42 -05:00
0c2eec6d99 tests: list restofworld_model_join in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:42 -05:00
46743b4609 tests: move navmesh_decode from LEGACY_COPIES to SHARED
It was the last tool carrying its own copy, so LEGACY_COPIES is empty now.
With the SHARED entry on main, test_switched_tools_import_the_helper_and_define_no_copy
fails ("'from report_paths import same_report_path' not found"); with this branch it passes.
2026-12-01 19:44:42 -05:00
048bb348ce tests: list rtti_scan in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:42 -05:00
940a89fef2 tests: list rbf0_index in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:42 -05:00
9bb2dfa701 tests: list odrp_7a in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:41 -05:00
1a35563b31 tests: list rbf0_tree in SHARED
The reviewers' red test: with this entry on main,
test_switched_tools_import_the_helper_and_define_no_copy fails with
"'from report_paths import same_report_path' not found"; with this branch
it passes.
2026-12-01 19:44:41 -05:00