From: Andrea Corallo Date: Fri, 27 Dec 2019 22:02:47 +0000 (+0100) Subject: move LATE_RELOCS just before VERY_LATE_RELOCS X-Git-Tag: emacs-28.0.90~2727^2~869 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=0bb5a47402313634b0e8654355e519388851e07f;p=emacs.git move LATE_RELOCS just before VERY_LATE_RELOCS --- diff --git a/src/pdumper.c b/src/pdumper.c index a35cc7ffcd6..85809c9978f 100644 --- a/src/pdumper.c +++ b/src/pdumper.c @@ -348,10 +348,10 @@ enum reloc_phase { /* First to run. Place here every relocation with no dependecy. */ EARLY_RELOCS, - /* Running after emacs relocations. */ + /* Late and very late relocs are relocated at the very last after + all hooks has been run. All lisp machinery is at disposal + (memory allocation allowed too). */ LATE_RELOCS, - /* Relocated at the very last after all hooks has been run. All - lisp machinery (allocation included) is at disposal. */ VERY_LATE_RELOCS, /* Fake, must be last. */ RELOC_NUM_PHASES @@ -5564,7 +5564,6 @@ pdumper_load (const char *dump_filename) dump_do_all_dump_reloc_for_phase (header, dump_base, EARLY_RELOCS); dump_do_all_emacs_relocations (header, dump_base); - dump_do_all_dump_reloc_for_phase (header, dump_base, LATE_RELOCS); dump_mmap_discard_contents (§ions[DS_DISCARDABLE]); for (int i = 0; i < ARRAYELTS (sections); ++i) @@ -5574,6 +5573,8 @@ pdumper_load (const char *dump_filename) initialization. */ for (int i = 0; i < nr_dump_hooks; ++i) dump_hooks[i] (); + + dump_do_all_dump_reloc_for_phase (header, dump_base, LATE_RELOCS); dump_do_all_dump_reloc_for_phase (header, dump_base, VERY_LATE_RELOCS); initialized = true;