mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-02 02:10:19 +02:00
Merge remote-tracking branch 'whippet/main' into wip-whippet
This commit is contained in:
commit
1e3ce66224
5 changed files with 28 additions and 0 deletions
|
@ -301,4 +301,17 @@ static inline void gc_safepoint(struct gc_mutator *mut) {
|
|||
gc_safepoint_slow(mut);
|
||||
}
|
||||
|
||||
GC_API_ void gc_safepoint_signal_inhibit(struct gc_mutator *mut);
|
||||
GC_API_ void gc_safepoint_signal_reallow(struct gc_mutator *mut);
|
||||
|
||||
static inline void gc_inhibit_preemption(struct gc_mutator *mut) {
|
||||
if (gc_safepoint_mechanism() == GC_SAFEPOINT_MECHANISM_SIGNAL)
|
||||
gc_safepoint_signal_inhibit(mut);
|
||||
}
|
||||
|
||||
static inline void gc_reallow_preemption(struct gc_mutator *mut) {
|
||||
if (gc_safepoint_mechanism() == GC_SAFEPOINT_MECHANISM_SIGNAL)
|
||||
gc_safepoint_signal_reallow(mut);
|
||||
}
|
||||
|
||||
#endif // GC_API_H_
|
||||
|
|
|
@ -203,6 +203,13 @@ void gc_write_barrier_slow(struct gc_mutator *mut, struct gc_ref obj,
|
|||
int* gc_safepoint_flag_loc(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
void gc_safepoint_slow(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
|
||||
void gc_safepoint_signal_inhibit(struct gc_mutator *mut) {
|
||||
GC_alloc_lock();
|
||||
}
|
||||
void gc_safepoint_signal_reallow(struct gc_mutator *mut) {
|
||||
GC_alloc_unlock();
|
||||
}
|
||||
|
||||
struct bdw_mark_state {
|
||||
struct GC_ms_entry *mark_stack_ptr;
|
||||
struct GC_ms_entry *mark_stack_limit;
|
||||
|
|
|
@ -869,6 +869,9 @@ gc_safepoint_slow(struct gc_mutator *mut) {
|
|||
heap_unlock(heap);
|
||||
}
|
||||
|
||||
void gc_safepoint_signal_inhibit(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
void gc_safepoint_signal_reallow(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
|
||||
static enum gc_trace_kind
|
||||
compute_trace_kind(enum gc_allocation_kind kind) {
|
||||
if (GC_CONSERVATIVE_TRACE) {
|
||||
|
|
|
@ -1081,6 +1081,9 @@ void gc_safepoint_slow(struct gc_mutator *mut) {
|
|||
heap_unlock(heap);
|
||||
}
|
||||
|
||||
void gc_safepoint_signal_inhibit(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
void gc_safepoint_signal_reallow(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
|
||||
struct gc_ephemeron* gc_allocate_ephemeron(struct gc_mutator *mut) {
|
||||
return gc_allocate(mut, gc_ephemeron_size(), GC_ALLOCATION_TAGGED);
|
||||
}
|
||||
|
|
|
@ -487,6 +487,8 @@ void gc_write_barrier_slow(struct gc_mutator *mut, struct gc_ref obj,
|
|||
|
||||
int* gc_safepoint_flag_loc(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
void gc_safepoint_slow(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
void gc_safepoint_signal_inhibit(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
void gc_safepoint_signal_reallow(struct gc_mutator *mut) { GC_CRASH(); }
|
||||
|
||||
static int collect_for_large_alloc(struct gc_mutator *mut, size_t npages) {
|
||||
size_t bytes = npages * mutator_semi_space(mut)->page_size;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue