[svn:parrot] r48460 - branches/unshared_buffers/src/gc

darbelo at svn.parrot.org darbelo at svn.parrot.org
Fri Aug 13 17:08:35 UTC 2010


Author: darbelo
Date: Fri Aug 13 17:08:34 2010
New Revision: 48460
URL: https://trac.parrot.org/parrot/changeset/48460

Log:
Prune the Variable_sized_pool struct of members that were only useful with cow.

Modified:
   branches/unshared_buffers/src/gc/alloc_resources.c
   branches/unshared_buffers/src/gc/gc_private.h

Modified: branches/unshared_buffers/src/gc/alloc_resources.c
==============================================================================
--- branches/unshared_buffers/src/gc/alloc_resources.c	Fri Aug 13 17:08:08 2010	(r48459)
+++ branches/unshared_buffers/src/gc/alloc_resources.c	Fri Aug 13 17:08:34 2010	(r48460)
@@ -23,7 +23,6 @@
 #include "gc_private.h"
 
 
-#define RECLAMATION_FACTOR 0.20
 #define WE_WANT_EVER_GROWING_ALLOCATIONS 0
 
 /* show allocated blocks on stderr */
@@ -673,8 +672,6 @@
     prev_block->prev = NULL;
 
     pool->total_allocated        = new_block->size;
-    pool->guaranteed_reclaimable = 0;
-    pool->possibly_reclaimable   = 0;
 }
 
 /*
@@ -751,9 +748,6 @@
     pool->compact                = compact;
     pool->minimum_block_size     = min_block;
     pool->total_allocated        = 0;
-    pool->guaranteed_reclaimable = 0;
-    pool->possibly_reclaimable   = 0;
-    pool->reclaim_factor         = RECLAMATION_FACTOR;
 
     return pool;
 }
@@ -820,13 +814,8 @@
         cur_block = next_block;
     }
 
-    dest->guaranteed_reclaimable += source->guaranteed_reclaimable;
-    dest->possibly_reclaimable   += source->possibly_reclaimable;
-
     source->top_block              = NULL;
     source->total_allocated        = 0;
-    source->possibly_reclaimable   = 0;
-    source->guaranteed_reclaimable = 0;
 }
 
 /*

Modified: branches/unshared_buffers/src/gc/gc_private.h
==============================================================================
--- branches/unshared_buffers/src/gc/gc_private.h	Fri Aug 13 17:08:08 2010	(r48459)
+++ branches/unshared_buffers/src/gc/gc_private.h	Fri Aug 13 17:08:34 2010	(r48460)
@@ -175,10 +175,6 @@
     void (*compact)(PARROT_INTERP, struct Memory_Pools *, struct Variable_Size_Pool *);
     size_t minimum_block_size;
     size_t total_allocated; /* total bytes allocated to this pool */
-    size_t guaranteed_reclaimable;     /* bytes that can definitely be reclaimed*/
-    size_t possibly_reclaimable;     /* bytes that can possibly be reclaimed
-                                      * (above plus COW-freed bytes) */
-    FLOATVAL reclaim_factor; /* minimum percentage we will reclaim */
 } Variable_Size_Pool;
 
 typedef struct Fixed_Size_Arena {


More information about the parrot-commits mailing list