emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

scratch/comp-static-data ab886f48966 05/16: comp.c: Only call comp_init_


From: Vibhav Pant
Subject: scratch/comp-static-data ab886f48966 05/16: comp.c: Only call comp_init_objs when not recursively loading.
Date: Thu, 19 Jan 2023 12:44:34 -0500 (EST)

branch: scratch/comp-static-data
commit ab886f489665be4bb96ce7159e7940b6ee78ec8c
Author: Vibhav Pant <vibhavp@gmail.com>
Commit: Vibhav Pant <vibhavp@gmail.com>

    comp.c: Only call comp_init_objs when not recursively loading.
    
    * src/comp.c (load_comp_unit): Only initialize comp_u->staticpro and
    comp_u->ephemeral when the current load is not recursive.
---
 src/comp.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/comp.c b/src/comp.c
index 2f90d6c54be..e76e17f9a61 100644
--- a/src/comp.c
+++ b/src/comp.c
@@ -7879,7 +7879,7 @@ load_comp_unit (struct Lisp_Native_Comp_Unit *comp_u, 
bool loading_dump,
       *freloc_link_table = freloc.link_table;
 
 #ifdef HAVE_STATIC_LISP_GLOBALS
-      if (comp_u->have_static_lisp_data)
+      if (comp_u->have_static_lisp_data && !recursive_load)
        {
          comp_u->staticpro = *data_staticpro;
          comp_u->ephemeral
@@ -7946,10 +7946,12 @@ load_comp_unit (struct Lisp_Native_Comp_Unit *comp_u, 
bool loading_dump,
         modifications.  */
       res = top_level_run (comp_u_lisp_obj);
 
+
       if (!comp_u->have_static_lisp_data)
        {
-         /* Make sure data_ephemeral_vec still exists after top_level_run has 
run.
-            Guard against sibling call optimization (or any other).  */
+         /* Make sure data_ephemeral_vec still exists after
+            top_level_run has run. Guard against sibling call
+            optimization (or any other).  */
          data_ephemeral_vec = data_ephemeral_vec;
          eassert (check_comp_unit_relocs (comp_u));
        }



reply via email to

[Prev in Thread] Current Thread [Next in Thread]