Branch: Tag:

2000-07-18

2000-07-18 05:48:20 by Martin Stjernholm <mast@lysator.liu.se>

Fixed tricky gc problems by implementing a gc-tailored call stack that can
be rotated. That also made the whole thing quite a bit less hairy.

Rev: src/array.c:1.78
Rev: src/array.h:1.21
Rev: src/gc.c:1.107
Rev: src/gc.h:1.55
Rev: src/mapping.c:1.93
Rev: src/mapping.h:1.27
Rev: src/multiset.c:1.25
Rev: src/multiset.h:1.13
Rev: src/object.c:1.136
Rev: src/object.h:1.49
Rev: src/program.c:1.251
Rev: src/program.h:1.96
Rev: src/svalue.c:1.84
Rev: src/testsuite.in:1.314

5:   \*/      /* -  * $Id: mapping.h,v 1.26 2000/07/06 23:25:26 mast Exp $ +  * $Id: mapping.h,v 1.27 2000/07/18 05:48:20 mast Exp $    */   #ifndef MAPPING_H   #define MAPPING_H
150:   unsigned gc_touch_all_mappings(void);   void gc_check_all_mappings(void);   void gc_mark_all_mappings(void); - void real_gc_cycle_check_mapping(struct mapping *m); - void real_gc_cycle_check_mapping_weak(struct mapping *m); + void real_gc_cycle_check_mapping(struct mapping *m, int weak);   void gc_cycle_check_all_mappings(void); -  + void gc_zap_ext_weak_refs_in_mappings(void);   void gc_free_all_unreferenced_mappings(void);   void simple_describe_mapping(struct mapping *m);   void debug_dump_mapping(struct mapping *m);
161:      #define allocate_mapping(X) dmalloc_touch(struct mapping *,debug_allocate_mapping(X))    - #define gc_cycle_check_mapping(X) \ -  enqueue_lifo(&gc_mark_queue, (queue_call) real_gc_cycle_check_mapping, (X)) - #define gc_cycle_check_mapping_weak(X) \ -  enqueue_lifo(&gc_mark_queue, (queue_call) real_gc_cycle_check_mapping_weak, (X)) + #define gc_cycle_check_mapping(X, WEAK) \ +  gc_cycle_enqueue((gc_cycle_check_cb *) real_gc_cycle_check_mapping, (X), (WEAK))      #endif /* MAPPING_H */