commit
ce241fd339
2
src/os.c
2
src/os.c
@ -195,7 +195,7 @@ static void* mi_win_virtual_alloc(void* addr, size_t size, size_t try_alignment,
|
|||||||
void* p = NULL;
|
void* p = NULL;
|
||||||
if (use_large_os_page(size, try_alignment)) {
|
if (use_large_os_page(size, try_alignment)) {
|
||||||
if (large_page_try_ok > 0) {
|
if (large_page_try_ok > 0) {
|
||||||
// if a large page page allocation fails, it seems the calls to VirtualAlloc get very expensive.
|
// if a large page allocation fails, it seems the calls to VirtualAlloc get very expensive.
|
||||||
// therefore, once a large page allocation failed, we don't try again for `large_page_try_ok` times.
|
// therefore, once a large page allocation failed, we don't try again for `large_page_try_ok` times.
|
||||||
large_page_try_ok--;
|
large_page_try_ok--;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user