<feed xmlns='http://www.w3.org/2005/Atom'>
<title>npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/runtime/src/base_reservation.h, branch docs/pso-cache-scope-note</title>
<subtitle>[no description]</subtitle>
<id>https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/atom?h=docs%2Fpso-cache-scope-note</id>
<link rel='self' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/atom?h=docs%2Fpso-cache-scope-note'/>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/'/>
<updated>2026-11-24T09:58:41+00:00</updated>
<entry>
<title>pe_loader: a relocation table is applied whatever RELOCS_STRIPPED says (Windows 11 measurement)</title>
<updated>2026-11-24T09:58:41+00:00</updated>
<author>
<name>Jan Trencansky</name>
<email>jan.trencansky@protonmail.com</email>
</author>
<published>2026-11-23T20:12:44+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=ca56a0d5eff2f6217a593babcfaff87d46daa15d'/>
<id>urn:sha1:ca56a0d5eff2f6217a593babcfaff87d46daa15d</id>
<content type='text'>
Zombins2 measured the Windows 11 (26200) loader with synthetic x64 DLLs in #8847. An image with
IMAGE_FILE_RELOCS_STRIPPED set and a relocation table was moved and fixed up when its base was taken. The
previous commit refused that case, while main relocated it. That is now back to main's behaviour: a moved
image with a table is fixed up whatever the flag says, and the flag refuses a move only when there is no
table. base_reservation::needed is back to main's test (the directory size) and no longer reserves for a
flag-set image with a table.

The core change stays: with the flag clear and no relocation directory, the image is moved with nothing
fixed up and the move is logged. That matches the measurement.

Windows also refused flag-set DLLs without a relocation directory at a free base (error 487), and it is not
known why. The loader keeps main's behaviour there and maps them at their base. runtime/README.md records
this as an open question, and loader_test's check for it no longer claims Windows parity. The flag-with-table
check now expects a move with the DIR64 fix-up applied.

Co-Authored-By: Claude Opus 5.5 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>pe_loader: move an image with no relocation directory, refuse only on IMAGE_FILE_RELOCS_STRIPPED</title>
<updated>2026-11-24T09:58:41+00:00</updated>
<author>
<name>Jan Trencansky</name>
<email>jan.trencansky@protonmail.com</email>
</author>
<published>2026-11-23T19:36:22+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=0ddf806359d30022a3152e61c93ed077212d25aa'/>
<id>urn:sha1:0ddf806359d30022a3152e61c93ed077212d25aa</id>
<content type='text'>
The loader refused any image whose preferred base was taken when it had no relocation directory. Windows'
loader decides on the file header flag instead (LdrRelocateImage, the same in Wine's perform_relocations and
ReactOS's LdrRelocateImageWithBias): IMAGE_FILE_RELOCS_STRIPPED set means the image cannot move and is
refused (STATUS_CONFLICTING_ADDRESSES); with the flag clear and an empty directory the image is moved with
nothing to fix up, as a second copy of such a DLL is.

map_image now does the same, for an EXE and a DLL alike: it refuses to move a flag-set image (also one that
has a relocation table, as Windows does), moves a flag-clear image without a directory and logs one
"[rt] loader: ... moved ... with no relocations" line, so a move without fix-ups shows in traces.
base_reservation::needed keeps reserving the main image's range for both kinds of image without
relocations, and now also for a flag-set image with a table, so the main image keeps its base wherever it
did before. The retail executable and every package DLL have a relocation table and the flag clear, so
neither path applies to them.

loader_test covers a flag-clear image moved when its base is held (it loads elsewhere, nothing is fixed
up, its DllMain runs), the same image with the flag set (refused), the flag at a free base (maps), and the
flag with a relocation table (refused). test_failed_dependency_not_registered's dependency shared its
parent's base and was refused for that; it now fails on its corrupt import table, which is what the test
describes.

Co-Authored-By: Claude Opus 5.5 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>Merge pull request #1942 from Felix Croasdale</title>
<updated>2026-11-22T15:39:37+00:00</updated>
<author>
<name>ItsNotRexed</name>
<email>300290919+ItsNotRexed@users.noreply.github.com</email>
</author>
<published>2026-11-22T15:39:37+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=6a4eff58161568699e54db15cb83884393515e5c'/>
<id>urn:sha1:6a4eff58161568699e54db15cb83884393515e5c</id>
<content type='text'>
</content>
</entry>
<entry>
<title>base_reservation: read LEONIDA_BASE_RESERVED with swscanf_s (MSVC C4996)</title>
<updated>2026-11-22T15:09:13+00:00</updated>
<author>
<name>Felix Croasdale</name>
<email>205819305+etcetera-yt@users.noreply.github.com</email>
</author>
<published>2026-11-22T15:09:13+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=74941a2411c89a9686b23ee8342f744a7807b77f'/>
<id>urn:sha1:74941a2411c89a9686b23ee8342f744a7807b77f</id>
<content type='text'>
swscanf at base_reservation.h:44 was the runtime build's only warning on
main 6a6704d, printed for five targets. swscanf_s takes no buffer sizes
for integer conversions, so the %llx:%llx parse is the same.

pe_loader_test now checks inherited(): a valid value, size 0, no size,
a non-hex base and no variable. Only arm64 Wine relaunches gta6rt, so a
Windows run never reached this parser before.

Co-Authored-By: Claude Opus 5.5 &lt;noreply@anthropic.com&gt;
</content>
</entry>
<entry>
<title>base_reservation: check SetEnvironmentVariableW and ResumeThread before waiting on the child</title>
<updated>2026-11-22T14:14:17+00:00</updated>
<author>
<name>Ash Hopkins</name>
<email>ashleighhopkins87@gmail.com</email>
</author>
<published>2026-11-22T14:14:17+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=427532c70c4dfe91577f8b2f48d25f371a0e9de0'/>
<id>urn:sha1:427532c70c4dfe91577f8b2f48d25f371a0e9de0</id>
<content type='text'>
Review on #1707: without the marker the child would not use the reservation and could relaunch again, and a
child left suspended would make the infinite wait hang. Both now end the child and return 1, as a failed
reservation already did.

AI-assisted. No game files.
</content>
</entry>
<entry>
<title>runtime: reserve a relocation-less image's range before arm64 Wine takes it</title>
<updated>2026-11-22T12:53:32+00:00</updated>
<author>
<name>Ash Hopkins</name>
<email>ashleighhopkins87@gmail.com</email>
</author>
<published>2026-11-22T11:25:05+00:00</published>
<link rel='alternate' type='text/html' href='https://upleb.uk/npub1w4dsu3e6hzjehh7l3c9njhtwwtgk9g209ylqf4tvdn2m07xjq06se9ett9/Leonida/commit/?id=d820ecfa63fa9939209e305d5f94cda59ca7f16f'/>
<id>urn:sha1:d820ecfa63fa9939209e305d5f94cda59ca7f16f</id>
<content type='text'>
An EXE without .reloc can only run at its ImageBase (0x140000000 by default; RT-22 asks whether the game's
is one). Under arm64 Wine on macOS (CrossOver's arm64 bottles, x86-64 code under FEX) the process's own
start-up allocations sit at 0x100000000 and up before gta6rt runs, so such an image failed with "preferred
base is taken". gta6rt now starts itself again suspended when the image has no relocations and its range is
not free, reserves [ImageBase, ImageBase + SizeOfImage) in the new process, resumes it and returns its exit
code; the loader commits the image inside that reservation. LEONIDA_BASE_RESERVED tells the new process,
which does not start itself again. Where the range is free at start-up (Windows, x86-64 Wine) nothing
changes.

tiny_game_fixed is the stand-in game linked /FIXED at 0x140000000; run_tiny_game_fixed and
run_tiny_game_fixed_exit_code run it. Arm64 bottle (CrossOver Preview 20260821, M2 Max): it maps at
0x140000000 and both tests pass, --dry-run and --init exit 0; with the relaunch disabled it fails as
before. The Rosetta (x86-64) bottle passes them too. The in-process loader tests that build relocation-less
images (loader, pe_loader_bounds, unimplemented_policy) still fail on arm64.

AI-assisted. No game files.
</content>
</entry>
</feed>
