From: bdemsky Date: Fri, 15 Apr 2011 23:53:49 +0000 (+0000) Subject: changes X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=6949aab0a85dcae77022be25f8ec90d839db83db;p=IRC.git changes --- diff --git a/Robust/src/Runtime/garbage.c b/Robust/src/Runtime/garbage.c index fcdfcc10..712096c8 100644 --- a/Robust/src/Runtime/garbage.c +++ b/Robust/src/Runtime/garbage.c @@ -37,7 +37,6 @@ extern deque* deques; #include "delaycomp.h" #endif -#define NUMPTRS 100 #ifndef INITIALHEAPSIZE_MB #define INITIALHEAPSIZE_MB (256) @@ -48,18 +47,6 @@ extern deque* deques; /* This define takes in how full the heap is initially and returns a new heap size to use */ #define HEAPSIZE(x,y) ((INTPTR)(x+y))*2 -#ifdef TASK -extern struct genhashtable * activetasks; -#ifndef MULTICORE -extern struct parameterwrapper * objectqueues[NUMCLASSES]; -#endif -extern struct genhashtable * failedtasks; -extern struct taskparamdescriptor *currtpd; -extern struct ctable *forward; -extern struct ctable *reverse; -extern struct RuntimeHash *fdtoobject; -#endif - #ifdef GARBAGESTATS #define MAXSTATS 500 long garbagearray[MAXSTATS]; diff --git a/Robust/src/Runtime/garbage.h b/Robust/src/Runtime/garbage.h index 3a286e50..fd6f57c3 100644 --- a/Robust/src/Runtime/garbage.h +++ b/Robust/src/Runtime/garbage.h @@ -7,6 +7,8 @@ #include "jni-private.h" #endif +#define NUMPTRS 100 + struct garbagelist { int size; struct garbagelist *next; @@ -52,6 +54,8 @@ struct listitem { #ifdef TASK void fixtags(); +extern struct pointerblock *taghead; +extern int tagindex; #endif #if defined(THREADS)||defined(DSTM)||defined(STM)||defined(MLP) diff --git a/Robust/src/Runtime/taskgarbage.c b/Robust/src/Runtime/taskgarbage.c index e2f08c40..8b256f3c 100644 --- a/Robust/src/Runtime/taskgarbage.c +++ b/Robust/src/Runtime/taskgarbage.c @@ -1,5 +1,23 @@ #include "garbage.h" +#include "runtime.h" +#include "structdefs.h" +#include "SimpleHash.h" +#include "GenericHashtable.h" + #ifdef TASK + +extern struct genhashtable * activetasks; +extern struct genhashtable * failedtasks; +extern struct taskparamdescriptor *currtpd; +extern struct ctable *forward; +extern struct ctable *reverse; +extern struct RuntimeHash *fdtoobject; + +#ifndef MULTICORE +extern struct parameterwrapper * objectqueues[NUMCLASSES]; +#endif + + void searchtaskroots() { { /* Update objectsets */