You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by xl...@apache.org on 2007/05/25 13:02:36 UTC

svn commit: r541616 - in /harmony/enhanced/drlvm/trunk/vm/gc_gen/src: common/space_tuner.cpp gen/gen.cpp

Author: xli
Date: Fri May 25 04:02:35 2007
New Revision: 541616

URL: http://svn.apache.org/viewvc?view=rev&rev=541616
Log:
Fix for outofmemory.* failures in Linux64

Modified:
    harmony/enhanced/drlvm/trunk/vm/gc_gen/src/common/space_tuner.cpp
    harmony/enhanced/drlvm/trunk/vm/gc_gen/src/gen/gen.cpp

Modified: harmony/enhanced/drlvm/trunk/vm/gc_gen/src/common/space_tuner.cpp
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/gc_gen/src/common/space_tuner.cpp?view=diff&rev=541616&r1=541615&r2=541616
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/gc_gen/src/common/space_tuner.cpp (original)
+++ harmony/enhanced/drlvm/trunk/vm/gc_gen/src/common/space_tuner.cpp Fri May 25 04:02:35 2007
@@ -233,6 +233,7 @@
       assert(max_heap_size_bytes >= gc->committed_heap_size);
       POINTER_SIZE_INT extend_heap_size = 0;
       POINTER_SIZE_INT potential_max_heap_size = max_tuning_size + max_heap_size_bytes - gc->committed_heap_size;
+      potential_max_heap_size -= LOS_HEAD_RESERVE_FOR_HEAP_NULL;
 
       //debug_adjust
       assert(!(potential_max_heap_size % SPACE_ALLOC_UNIT));

Modified: harmony/enhanced/drlvm/trunk/vm/gc_gen/src/gen/gen.cpp
URL: http://svn.apache.org/viewvc/harmony/enhanced/drlvm/trunk/vm/gc_gen/src/gen/gen.cpp?view=diff&rev=541616&r1=541615&r2=541616
==============================================================================
--- harmony/enhanced/drlvm/trunk/vm/gc_gen/src/gen/gen.cpp (original)
+++ harmony/enhanced/drlvm/trunk/vm/gc_gen/src/gen/gen.cpp Fri May 25 04:02:35 2007
@@ -360,7 +360,7 @@
 void gc_gen_adjust_heap_size(GC_Gen* gc, int64 pause_time)
 {
   if(gc_match_kind((GC*)gc, MINOR_COLLECTION)) return;
-  if(gc->committed_heap_size == max_heap_size_bytes) return;
+  if(gc->committed_heap_size == max_heap_size_bytes - LOS_HEAD_RESERVE_FOR_HEAP_NULL) return;
   
   Mspace* mos = gc->mos;
   Fspace* nos = gc->nos;