Commit Graph

18350 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
2948cf3e49 awc_shorts: refuse a catalog collision before creating the output folder
Review follow-up from #934: the bank export directory check ran after
os.makedirs, so a refused run left an empty output folder. Both
collision checks now run first, and a test checks that out/ is not
created.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-02 10:47:43 +01: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
a990504ee6 Record the commits of #693 (abnalstlll-byte) in the history of this carry
The tree is the one already resolved on top of main; this merge only keeps the
author's four commits as ancestors, as CONTRIBUTING.md asks for a carry.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-12-02 08:29:57 +01:00
a917c54d6a Merge pull request #3057 from OreoFR/feat/launcher-update
launcher: check for updates at start and update in one click (LAUNCHER-UPDATE)
2026-12-02 07:24:23 +00: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
d9ac7f6f0c Merge remote-tracking branch 'origin/main' into feat/launcher-update
# Conflicts:
#	tools/leonida_launcher.py
2026-12-02 08:07:23 +01:00
229d352ee3 Merge pull request #3058 from OreoFR/carry/hwrt-2972
d3d12: hardware ray tracing on DXR 1.1 (LEONIDA_HW_RT, off: a trial) - carry of #2972
2026-12-02 06:54:01 +00:00
d94e764d62 Merge pull request #3056 from OreoFR/fix/launcher-precompile-all-needs-prepare
launcher: Precompile every pipeline ticks Prepare shaders (LAUNCHER-PRECOMPILE-ALL-NEEDS-PREPARE)
2026-12-02 06:45:52 +00:00
094be1f323 launcher: show an update beside PLAY, not only in the status bar
The first window test showed the bar line at the very bottom, easy to
miss, and its text pointed at a button "above" that was beside it. An
update now shows as a framed "Update available: N new commits" with its
Update button next to PLAY. The bar keeps the other notes (zip copy, no
git, a failed check).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-02 07:44:39 +01:00
43af833d19 Merge remote-tracking branch 'origin/main' into carry/hwrt-2972
# Conflicts:
#	d3d12/docs/switches.md
2026-12-02 07:40:14 +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
c43f309985 launcher: Precompile every pipeline ticks Prepare shaders (LAUNCHER-PRECOMPILE-ALL-NEEDS-PREPARE)
switch_args passes -PrecompileAll only with the shader preparation on, so the
new box did nothing when Prepare shaders before starting was off. A player hit
this right after #2986. Ticking the first box now ticks the second, and turning
the preparation off clears the first. A note line under the options says so.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-02 07:25:20 +01:00
daf7242f2e Merge remote-tracking branch 'origin/main' into carry/hwrt-2972
# Conflicts:
#	d3d12/scripts/play-nvidia.ps1
#	scripts/play-d3d12.ps1
2026-12-02 06:57:33 +01:00
f37c4a87d6 Merge pull request #2756 from IgorAntunes66/pr/seriesx-dlss-black-world
d3d12: leave FidelityFX maximum-size vtable patch off by default (D3D12-SERIESX-FSR-MAX-SCALED)
2026-12-02 05:52:36 +00:00
5b005f8bb9 d3d12/docs/switches.md: list LEONIDA_FSR_MAX_SCALED
The merge queue's tests found the page out of date once this branch met main.
Regenerated with tools/d3d12_switches.py after merging main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-02 06:31:19 +01:00
87ef956700 Merge remote-tracking branch 'origin/main' into pr2756fix 2026-12-02 06:30:45 +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
2051ccd0aa docs/testing.md: red_green.py --mutate results include compiler crashed; one way to remove the worktree, default folder or --work-dir (review) 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
df480832d7 scripts: red_green.py keeps the test files a tree has in one place, side() (review) 2026-12-02 05:19:44 +01:00
3b3e5ee5da docs/testing.md: red_green.py --work-dir leaves its worktree registered; git worktree remove <dir>/tree removes it (review) 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
8422def759 Merge pull request #3032 from enlight3d/cold-start-wait-clock
d3d12: time each begin and end of a pipeline wait under its count's lock (D3D12-COLD-START-SKIPS follow-up)
2026-12-02 03:16:02 +00:00