mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-05-04 22:49:32 +03:00
don't reset a segment thread id when iterating
This commit is contained in:
parent
065f46cefb
commit
3f69119936
1 changed files with 1 additions and 2 deletions
|
@ -82,8 +82,7 @@ static bool mi_arena_segment_os_clear_abandoned(mi_segment_t* segment, bool take
|
||||||
segment->abandoned_os_prev = NULL;
|
segment->abandoned_os_prev = NULL;
|
||||||
mi_atomic_decrement_relaxed(&subproc->abandoned_count);
|
mi_atomic_decrement_relaxed(&subproc->abandoned_count);
|
||||||
mi_atomic_decrement_relaxed(&subproc->abandoned_os_list_count);
|
mi_atomic_decrement_relaxed(&subproc->abandoned_os_list_count);
|
||||||
if (take_lock) {
|
if (take_lock) { // don't reset the thread_id when iterating
|
||||||
// don't set the thread_id when iterating
|
|
||||||
mi_atomic_store_release(&segment->thread_id, _mi_thread_id());
|
mi_atomic_store_release(&segment->thread_id, _mi_thread_id());
|
||||||
}
|
}
|
||||||
reclaimed = true;
|
reclaimed = true;
|
||||||
|
|
Loading…
Add table
Reference in a new issue