From 72dee3fc5239f592523fd4307f436cc1baf82eac Mon Sep 17 00:00:00 2001 From: bdemsky Date: Sat, 16 Jul 2011 00:02:46 +0000 Subject: [PATCH] more odd core count bugs --- Robust/src/Runtime/bamboo/pmc_forward.c | 6 ++++-- Robust/src/Runtime/bamboo/pmc_garbage.c | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/Robust/src/Runtime/bamboo/pmc_forward.c b/Robust/src/Runtime/bamboo/pmc_forward.c index d886b552..c60d7ce5 100644 --- a/Robust/src/Runtime/bamboo/pmc_forward.c +++ b/Robust/src/Runtime/bamboo/pmc_forward.c @@ -86,8 +86,10 @@ void pmc_processunits() { for(;regionnumregions[regionnum].highunit=NUMPMCUNITS; pmc_heapptr->regions[regionnum].endptr=pmc_heapptr->units[NUMPMCUNITS-1].endptr; - pmc_heapptr->regions[regionnum+1].startptr=pmc_heapptr->units[NUMPMCUNITS-1].endptr; - pmc_heapptr->regions[regionnum+1].lowunit=NUMPMCUNITS; + if ((regionnum+1)regions[regionnum+1].startptr=pmc_heapptr->units[NUMPMCUNITS-1].endptr; + pmc_heapptr->regions[regionnum+1].lowunit=NUMPMCUNITS; + } } } diff --git a/Robust/src/Runtime/bamboo/pmc_garbage.c b/Robust/src/Runtime/bamboo/pmc_garbage.c index 3a9f99dc..8933bcda 100644 --- a/Robust/src/Runtime/bamboo/pmc_garbage.c +++ b/Robust/src/Runtime/bamboo/pmc_garbage.c @@ -66,7 +66,7 @@ void pmc_init() { void *finishptr=(i+1)regions[i+1].lastptr:pmc_heapptr->regions[i].endptr; struct pmc_region *region=&pmc_heapptr->regions[i]; unsigned int startindex=region->lowunit; - unsigned int endindex=pmc_heapptr->regions[i+1].highunit; + unsigned int endindex=(i+1)regions[i+1].highunit:pmc_heapptr->regions[i].highunit; //tprintf("Free space in partition %u from %x to %x\n", i, startptr, finishptr); for(unsigned int index=startindex;indexunits[index].endptr; -- 2.34.1