The ptr_table arena variables and code is only needed for ithreads.
authorNicholas Clark <nick@ccl4.org>
Sat, 7 May 2005 16:08:16 +0000 (16:08 +0000)
committerNicholas Clark <nick@ccl4.org>
Sat, 7 May 2005 16:08:16 +0000 (16:08 +0000)
p4raw-id: //depot/perl@24413

intrpvar.h
sv.c

index 9688541..bca17b0 100644 (file)
@@ -261,7 +261,9 @@ PERLVAR(Ixpvmg_root,        XPVMG *)        /* free xpvmg list */
 PERLVAR(Ixpvlv_root,   XPVLV *)        /* free xpvlv list */
 PERLVAR(Ixpvbm_root,   XPVBM *)        /* free xpvbm list */
 PERLVAR(Ihe_root,      HE *)           /* free he list */
+#if defined(USE_ITHREADS)
 PERLVAR(Ipte_root,     struct ptr_tbl_ent *)   /* free ptr_tbl_ent list */
+#endif
 PERLVAR(Inice_chunk,   char *)         /* a nice chunk of memory to reuse */
 PERLVAR(Inice_chunk_size,      U32)    /* how nice the chunk of memory is */
 
@@ -438,8 +440,9 @@ PERLVAR(Ixpvmg_arenaroot,XPVMG*)    /* list of allocated xpvmg areas */
 PERLVAR(Ixpvlv_arenaroot,XPVLV*)       /* list of allocated xpvlv areas */
 PERLVAR(Ixpvbm_arenaroot,XPVBM*)       /* list of allocated xpvbm areas */
 PERLVAR(Ihe_arenaroot, HE *)           /* list of allocated he areas */
+#if defined(USE_ITHREADS)
 PERLVAR(Ipte_arenaroot,        struct ptr_tbl_ent *) /* list of allocated he areas */
-
+#endif
      /* 5.6.0 stopped here */
 
 PERLVAR(Ipsig_pend, int *)             /* per-signal "count" of pending */
diff --git a/sv.c b/sv.c
index c79d527..be65857 100644 (file)
--- a/sv.c
+++ b/sv.c
@@ -625,6 +625,7 @@ Perl_sv_free_arenas(pTHX)
     PL_he_arenaroot = 0;
     PL_he_root = 0;
 
+#if defined(USE_ITHREADS)
     {
        struct ptr_tbl_ent *pte;
        struct ptr_tbl_ent *pte_next;
@@ -635,6 +636,7 @@ Perl_sv_free_arenas(pTHX)
     }
     PL_pte_arenaroot = 0;
     PL_pte_root = 0;
+#endif
 
     if (PL_nice_chunk)
        Safefree(PL_nice_chunk);
@@ -11680,8 +11682,10 @@ perl_clone_using(PerlInterpreter *proto_perl, UV flags,
     PL_xpvbm_root      = NULL;
     PL_he_arenaroot    = NULL;
     PL_he_root         = NULL;
+#if defined(USE_ITHREADS)
     PL_pte_arenaroot   = NULL;
     PL_pte_root                = NULL;
+#endif
     PL_nice_chunk      = NULL;
     PL_nice_chunk_size = 0;
     PL_sv_count                = 0;