21 #define cant_discard_ref_i(ref_i) \
22 array_get_at(proc_p->past_msgs, ref_i)->dest_t >= current_gvt
28 while(cant_discard_ref_i(j)){
34 static inline void fossil_lp_collect(
simtime_t current_gvt)
37 array_count_t past_i = first_discardable_ref(current_gvt, proc_p);
38 past_i = model_allocator_fossil_lp_collect(past_i);
43 j -= (array_get_at(proc_p->sent_msgs, sent_i) == NULL);
45 array_truncate_first(proc_p->sent_msgs, sent_i);
48 msg_allocator_free(array_get_at(proc_p->past_msgs, j));
50 array_truncate_first(proc_p->past_msgs, past_i);
53 void fossil_collect(
simtime_t current_gvt)
56 remote_msg_map_fossil_collect(current_gvt);
57 msg_allocator_fossil_collect(current_gvt);
60 for (uint64_t i = lp_id_first; i < lp_id_end; ++i) {
62 fossil_lp_collect(current_gvt);