5 struct generation_statistics {
13 struct gc_statistics {
14 generation_statistics generations[gen_count];
18 u64 code_blocks_scanned;
22 /* The data heap we're collecting */
25 /* sometimes we grow the heap */
26 bool growing_data_heap;
27 data_heap *old_data_heap;
29 /* Which generation is being collected */
32 /* If true, we are collecting aging space for the second time, so if it is still
33 full, we go on to collect tenured */
34 bool collecting_aging_again;
36 /* GC start time, for benchmarking */
41 explicit gc_state(data_heap *data_, bool growing_data_heap_, cell collecting_gen_);
44 inline bool collecting_nursery_p()
46 return collecting_gen == nursery_gen;
49 inline bool collecting_aging_p()
51 return collecting_gen == aging_gen;
54 inline bool collecting_tenured_p()
56 return collecting_gen == tenured_gen;
59 inline bool collecting_accumulation_gen_p()
61 return ((collecting_aging_p() && !collecting_aging_again)
62 || collecting_tenured_p());
66 VM_C_API void inline_gc(cell *gc_roots_base, cell gc_roots_size, factor_vm *myvm);