runtime support for read only TRANSREADS
[IRC.git] / Robust / src / Runtime / garbage.c
index 1ef15582de2d50262d168fae510c5257221b4e91..5736285fc1c3fdbf84b9011a0586b72be910ae34 100644 (file)
 
 #define NUMPTRS 100
 
-#define INITIALHEAPSIZE 256*1024*1024
-#define GCPOINT(x) ((int)((x)*0.99))
+#define INITIALHEAPSIZE 1024*1024*1024L
+#define GCPOINT(x) ((INTPTR)((x)*0.99))
 /* This define takes in how full the heap is initially and returns a new heap size to use */
-#define HEAPSIZE(x,y) ((int)(x+y))*2
+#define HEAPSIZE(x,y) ((INTPTR)(x+y))*2
 
 #ifdef TASK
 extern struct genhashtable * activetasks;
@@ -742,9 +742,9 @@ void * mygcmalloc(struct garbagelist * stackptr, int size) {
 
     /* Grow the to heap if necessary */
     {
-      int curr_heapsize=curr_heaptop-curr_heapbase;
-      int to_heapsize=to_heaptop-to_heapbase;
-      int last_heapsize=0;
+      INTPTR curr_heapsize=curr_heaptop-curr_heapbase;
+      INTPTR to_heapsize=to_heaptop-to_heapbase;
+      INTPTR last_heapsize=0;
       if (lastgcsize>0) {
        last_heapsize=HEAPSIZE(lastgcsize, size);
        if ((last_heapsize&7)!=0)