pike.git / src / gc.c

version» Context lines:

pike.git/src/gc.c:23:   #include "constants.h"   #include "interpret.h"   #include "bignum.h"      #include "gc.h"   #include "main.h"   #include <math.h>      #include "block_alloc.h"    - RCSID("$Id: gc.c,v 1.152 2003/01/29 15:55:25 mast Exp $"); + RCSID("$Id: gc.c,v 1.153 2003/01/29 18:04:40 mast Exp $");      /* Run garbage collect approximately every time    * 20 percent of all arrays, objects and programs is    * garbage.    */      #define GC_CONST 20   #define MIN_ALLOC_THRESHOLD 1000   #define MAX_ALLOC_THRESHOLD 10000000   #define MULTIPLIER 0.9
pike.git/src/gc.c:1979:   int do_gc(void)   {    double tmp;    int start_num_objs, objs, pre_kill_objs;    double multiplier;    struct array *a;    struct multiset *l;    struct mapping *m;    struct program *p;    struct object *o; - #ifdef PIKE_DEBUG +    #ifdef HAVE_GETHRTIME    hrtime_t gcstarttime = 0;   #endif -  + #ifdef PIKE_DEBUG    unsigned destroy_count, obj_count;    ONERROR uwp;   #endif       if(Pike_in_gc) return 0;    init_gc();    Pike_in_gc=GC_PASS_PREPARE;    gc_debug = d_flag;   #ifdef PIKE_DEBUG    SET_ONERROR(uwp, fatal_on_error, "Shouldn't get an exception inside the gc.\n");