pike.git / src / gc.c

version» Context lines:

pike.git/src/gc.c:405: Inside #if defined(PIKE_DEBUG)
  static unsigned mark_live, frame_rot, link_search;   static unsigned gc_extra_refs = 0;   static unsigned tot_cycle_checked = 0, tot_mark_live = 0, tot_frame_rot = 0;   static unsigned gc_rec_frame_seq_max;   #endif      static unsigned rec_frames, link_frames, free_extra_frames;   static unsigned max_rec_frames, max_link_frames;   static unsigned tot_max_rec_frames = 0, tot_max_link_frames = 0, tot_max_free_extra_frames = 0;    + #ifndef PIKE_NEW_BLOCK_ALLOC   #undef INIT_BLOCK   #define INIT_BLOCK(f) do { \    if (++rec_frames > max_rec_frames) \    max_rec_frames = rec_frames; \    } while (0)   #undef EXIT_BLOCK   #define EXIT_BLOCK(f) do { \    DO_IF_DEBUG ({ \    if (f->rf_flags & GC_FRAME_FREED) \    gc_fatal (f->data, 0, "Freeing gc_rec_frame twice.\n"); \    f->rf_flags |= GC_FRAME_FREED; \    f->u.link_top = (struct link_frame *) (ptrdiff_t) -1; \    f->prev = f->next = f->cycle_id = f->cycle_piece = \    (struct gc_rec_frame *) (ptrdiff_t) -1; \    }); \    rec_frames--; \    } while (0)    - #ifndef PIKE_NEW_BLOCK_ALLOC +    BLOCK_ALLOC_FILL_PAGES (gc_rec_frame, 2)   #else   #include "gjalloc.h"      struct block_allocator gc_rec_frame_allocator =    BA_INIT(sizeof(struct gc_rec_frame), 4096/sizeof(struct gc_rec_frame));      static INLINE void really_free_gc_rec_frame(struct gc_rec_frame * f) {   #ifdef PIKE_DEBUG    if (f->rf_flags & GC_FRAME_FREED)
pike.git/src/gc.c:557:   #ifdef PIKE_DEBUG   #define INIT_BLOCK(X) \    (X)->flags=(X)->refs=(X)->weak_refs=(X)->xrefs=0; \    (X)->saved_refs=-1; \    (X)->frame = 0;   #else   #define INIT_BLOCK(X) \    (X)->flags=(X)->refs=(X)->weak_refs=0; \    (X)->frame = 0;   #endif + #undef EXIT_BLOCK + #define EXIT_BLOCK(f)      #undef get_marker   #define get_marker debug_get_marker   #undef find_marker   #define find_marker debug_find_marker      PTR_HASH_ALLOC_FIXED_FILL_PAGES(marker,2)      #undef get_marker   #define get_marker(X) ((struct marker *) debug_malloc_pass(debug_get_marker(X)))