mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-01-15 01:29:11 +08:00
enable eager delay even on overcommit systems
This commit is contained in:
parent
08e9d4b6c1
commit
f2bfaa74fe
@ -580,8 +580,8 @@ static mi_segment_t* mi_segment_init(mi_segment_t* segment, size_t required, mi_
|
||||
|
||||
// Initialize parameters
|
||||
const bool eager_delayed = (page_kind <= MI_PAGE_MEDIUM && // don't delay for large objects
|
||||
!_mi_os_has_overcommit() && // never delay on overcommit systems
|
||||
_mi_current_thread_count() > 2 && // do not delay for the first N threads
|
||||
// !_mi_os_has_overcommit() && // never delay on overcommit systems
|
||||
_mi_current_thread_count() > 1 && // do not delay for the first N threads
|
||||
tld->count < (size_t)mi_option_get(mi_option_eager_commit_delay));
|
||||
const bool eager = !eager_delayed && mi_option_is_enabled(mi_option_eager_commit);
|
||||
bool commit = eager; // || (page_kind >= MI_PAGE_LARGE);
|
||||
|
Loading…
x
Reference in New Issue
Block a user