2001-06-27
2001-06-27 02:06:41 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>
-
ffb3909f6a1d8592dbf181641b1d6be4855c55fe
(17 lines)
(+11/-6)
[
Show
| Annotate
]
Branch: 7.9
fixed debug routines to work better
Rev: src/gc.c:1.155
30:
#include "block_alloc.h"
- RCSID("$Id: gc.c,v 1.154 2001/06/26 21:03:49 hubbe Exp $");
+ RCSID("$Id: gc.c,v 1.155 2001/06/27 02:06:41 hubbe Exp $");
/* Run garbage collect approximately every time
* 20 percent of all arrays, objects and programs is
774:
{
if(m->data == (struct mapping_data *)a)
{
- fprintf(stderr,"%*s**Describing mapping:\n",indent,"");
+ fprintf(stderr,"%*s**Describing mapping for this data block:\n",indent,"");
debug_dump_mapping((struct mapping *)m);
- describe_something( m, T_MAPPING, indent+2,depth-1,flags);
+
}
}
break;
1059: Inside #if defined(PIKE_DEBUG)
{
int tmp, orig_in_gc = Pike_in_gc;
void *orig_check_for=check_for;
- if(!Pike_in_gc)
+ int i=0;
+ if(!marker_blocks)
+ {
+ i=1;
init_gc();
-
+ }
Pike_in_gc = GC_PASS_LOCATE;
/* Disable debug, this may help reduce recursion bugs */
1117: Inside #if defined(PIKE_DEBUG)
#endif
Pike_in_gc = orig_in_gc;
- if(!Pike_in_gc)
- exit_gc();
+ if(i) exit_gc();
d_flag=tmp;
}
#endif
2185: Inside #if defined(PIKE_DEBUG)
if (n != (unsigned) num_objects)
fatal("Object count wrong in gc; expected %d, got %d.\n", num_objects, n);
get_marker(rec_list.data)->flags |= GC_MIDDLETOUCHED;
+ #if 0 /* Temporarily disabled - Hubbe */
#ifdef DEBUG_MALLOC
PTR_HASH_LOOP(marker, i, m)
if (!(m->flags & (GC_MIDDLETOUCHED|GC_WEAK_FREED)) &&
2200: Inside #if defined(PIKE_DEBUG) and #if defined(DEBUG_MALLOC)
fatal("Fatal in garbage collector.\n");
}
#endif
+ #endif
GC_VERBOSE_DO(fprintf(stderr, "| middletouch\n"));
}
#endif