pike.git / src / gc.c

version» Context lines:

pike.git/src/gc.c:1:   /*   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: gc.c,v 1.209 2003/03/14 15:50:44 grubba Exp $ + || $Id: gc.c,v 1.210 2003/03/29 22:46:45 mast Exp $   */      #include "global.h"      struct callback *gc_evaluator_callback=0;      #include "array.h"   #include "multiset.h"   #include "mapping.h"   #include "object.h"
pike.git/src/gc.c:26:   #include "interpret.h"   #include "bignum.h"   #include "pike_threadlib.h"      #include "gc.h"   #include "main.h"   #include <math.h>      #include "block_alloc.h"    - RCSID("$Id: gc.c,v 1.209 2003/03/14 15:50:44 grubba Exp $"); + RCSID("$Id: gc.c,v 1.210 2003/03/29 22:46:45 mast Exp $");      int gc_enabled = 1;      /* These defaults are only guesses and hardly tested at all. Please improve. */   double gc_garbage_ratio_low = 0.2;   double gc_time_ratio = 0.05;   double gc_garbage_ratio_high = 0.5;      /* This slowness factor approximately corresponds to the average over    * the last ten gc rounds. (0.9 == 1 - 1/10) */
pike.git/src/gc.c:871: Inside #if defined(PIKE_DEBUG)
      fprintf(stderr,"%*s**Program id: %ld, flags: %x\n",indent,"",    (long)(p->id),    p->flags);       if(p->flags & PROGRAM_HAS_C_METHODS)    {    fprintf(stderr,"%*s**The program was written in C.\n",indent,"");    }    -  tmp = debug_get_program_line(p, &line); -  if(strcmp(tmp, "-")) -  { +  tmp = low_get_program_line_plain(p, &line, 1); +  if (tmp) {    fprintf(stderr,"%*s**Location: %s:%ld\n",    indent, "", tmp, (long)line);    foo=1; -  +  free (tmp);    break;    }   #if 0    if(!foo && p->num_linenumbers>1 && EXTRACT_UCHAR(p->linenumbers)=='\177')    {    fprintf(stderr,"%*s**From file: %s\n",indent,"",p->linenumbers+1);    foo=1;    }   #endif   
pike.git/src/gc.c:1044:    } else   #endif /* DEBUG_MALLOC */    if (((ptrdiff_t)a) & 3) {    fprintf(stderr,"%*s**Location: %p Type: %s Misaligned address\n",indent,"",a,    get_name_of_type(t));    } else {    fprintf(stderr,"%*s**Location: %p Type: %s Refs: %d\n",indent,"",a,    get_name_of_type(t),    *(INT32 *)a);    +  low_describe_something(a,t,indent,depth,flags,inblock); +    #ifdef DEBUG_MALLOC    if(!(flags & DESCRIBE_NO_DMALLOC))    debug_malloc_dump_references(a,indent+2,depth-1,flags);   #endif -  -  low_describe_something(a,t,indent,depth,flags,inblock); +     }       fprintf(stderr,"%*s*******************\n",indent,"");    d_flag=tmp;   }      PMOD_EXPORT void describe(void *x)   {    void *inblock;    int type = attempt_to_identify(x, &inblock);