mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-07-05 03:04:36 +03:00
fix cleanup size parameter
This commit is contained in:
parent
b5cc16b983
commit
80dc7a3eb0
1 changed files with 1 additions and 1 deletions
2
src/os.c
2
src/os.c
|
@ -723,7 +723,7 @@ static bool mi_os_resetx(void* addr, size_t size, bool reset, mi_stats_t* stats)
|
||||||
else _mi_stat_decrease(&stats->reset, csize);
|
else _mi_stat_decrease(&stats->reset, csize);
|
||||||
if (!reset) return true; // nothing to do on unreset!
|
if (!reset) return true; // nothing to do on unreset!
|
||||||
|
|
||||||
_mi_call_user_cleanup(start, size);
|
_mi_call_user_cleanup(start, csize);
|
||||||
|
|
||||||
#if defined(_WIN32)
|
#if defined(_WIN32)
|
||||||
// Testing shows that for us (on `malloc-large`) MEM_RESET is 2x faster than DiscardVirtualMemory
|
// Testing shows that for us (on `malloc-large`) MEM_RESET is 2x faster than DiscardVirtualMemory
|
||||||
|
|
Loading…
Add table
Reference in a new issue