diff options
| author | Jan Trencansky <jan.trencansky@protonmail.com> | 2026-11-23 15:12:44 -0500 |
|---|---|---|
| committer | Jan Trencansky <jan.trencansky@protonmail.com> | 2026-11-24 04:58:41 -0500 |
| commit | ca56a0d5eff2f6217a593babcfaff87d46daa15d (patch) | |
| tree | 6807765965a62150a371a00fb0d9ad33be4684da /runtime/src/main.cpp | |
| parent | 0ddf806359d30022a3152e61c93ed077212d25aa (diff) | |
pe_loader: a relocation table is applied whatever RELOCS_STRIPPED says (Windows 11 measurement)
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 <noreply@anthropic.com>
Diffstat (limited to 'runtime/src/main.cpp')
0 files changed, 0 insertions, 0 deletions