small bug fix
authorbdemsky <bdemsky>
Sat, 16 Jul 2011 08:59:52 +0000 (08:59 +0000)
committerbdemsky <bdemsky>
Sat, 16 Jul 2011 08:59:52 +0000 (08:59 +0000)
Robust/src/Runtime/bamboo/pmc_mem.c

index be245173b724f34b6b083764c1c98064629cc02d..ac25f6b52e7db242f68c01ec0d1193e41c908d30 100644 (file)
@@ -13,7 +13,7 @@ void * pmc_alloc(unsigned int * numbytesallocated, unsigned int minimumbytes) {
     void *startptr=pmc_heapptr->regions[i].lastptr;
     void *finishptr=(i+1)<NUMCORES4GC?pmc_heapptr->regions[i+1].lastptr:pmc_heapptr->regions[i].endptr;
     
-    if ((finishptr-startptr)>memcheck) {
+    if ((finishptr-startptr)>=memcheck) {
       struct pmc_region *region=&pmc_heapptr->regions[i];
       tmc_spin_mutex_lock(&region->lock);
       startptr=region->lastptr;