upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/test/loader_test.cpp
diff options
context:
space:
mode:
authorJan Trencansky <jan.trencansky@protonmail.com>2026-11-24 05:00:08 -0500
committerJan Trencansky <jan.trencansky@protonmail.com>2026-11-24 05:00:08 -0500
commitbb256ebbf32d7493e3d867923ec737e60d3f9f9d (patch)
tree8a20210e80cb4b0f0736bcd750c2c9753b48b219 /runtime/test/loader_test.cpp
parentca56a0d5eff2f6217a593babcfaff87d46daa15d (diff)
pe_loader: the relocation-move notes stop citing the old pull request number
The Windows 11 measurement behind this behaviour was posted in a review of pull request 8847 of the original repository, which went private on 2026-11-23, so its link and the "#8847" references in pe_loader.cpp and loader_test.cpp lead nowhere now. runtime/README.md keeps the measurement and the open question in its own words and names where it came from; the code comments point at the README. No behaviour changes. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'runtime/test/loader_test.cpp')
-rw-r--r--runtime/test/loader_test.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/runtime/test/loader_test.cpp b/runtime/test/loader_test.cpp
index 926becd12..6930878a9 100644
--- a/runtime/test/loader_test.cpp
+++ b/runtime/test/loader_test.cpp
@@ -655,10 +655,10 @@ void test_initialise_rejects() {
655} 655}
656 656
657// IMAGE_FILE_RELOCS_STRIPPED against a relocation directory, when the preferred base is taken. Measured on the 657// IMAGE_FILE_RELOCS_STRIPPED against a relocation directory, when the preferred base is taken. Measured on the
658// Windows 11 (26200) loader with synthetic DLLs (#8847): with no relocation directory the flag refuses the move and 658// Windows 11 (26200) loader with synthetic DLLs (runtime/README.md): with no relocation directory the flag refuses
659// an image with the flag clear is moved with nothing fixed up; with a relocation table the image is moved and fixed 659// the move and an image with the flag clear is moved with nothing fixed up; with a relocation table the image is
660// up whatever the flag says. The DllMain stub stores through an absolute address in this process, not in the image, 660// moved and fixed up whatever the flag says. The DllMain stub stores through an absolute address in this process,
661// so it runs correctly wherever the image lands. 661// not in the image, so it runs correctly wherever the image lands.
662void test_moved_without_relocations() { 662void test_moved_without_relocations() {
663 auto img = make_image(); 663 auto img = make_image();
664 auto* nt = nt_of(img); 664 auto* nt = nt_of(img);
@@ -706,7 +706,7 @@ void test_moved_without_relocations() {
706 if (held) VirtualFree(held, 0, MEM_RELEASE); 706 if (held) VirtualFree(held, 0, MEM_RELEASE);
707 { 707 {
708 // At a free base such an image maps, as it did before. Not Windows parity: the Windows 11 loader refused these 708 // At a free base such an image maps, as it did before. Not Windows parity: the Windows 11 loader refused these
709 // DLLs (error 487) at a free base too, for a reason not yet known (#8847); runtime/README.md keeps the question. 709 // DLLs (error 487) at a free base too, for a reason not yet known; runtime/README.md keeps the question.
710 auto stripped = img; 710 auto stripped = img;
711 nt_of(stripped)->FileHeader.Characteristics |= IMAGE_FILE_RELOCS_STRIPPED; 711 nt_of(stripped)->FileHeader.Characteristics |= IMAGE_FILE_RELOCS_STRIPPED;
712 expect_loads("an image with IMAGE_FILE_RELOCS_STRIPPED and no relocations maps at its free base", stripped); 712 expect_loads("an image with IMAGE_FILE_RELOCS_STRIPPED and no relocations maps at its free base", stripped);