Signal to the OS that the address range is no longer in use but may be used later again. This will release physical memory pages and reduce swapping while keeping the memory committed. We page align to a conservative area inside the range to reset.
| 1073 | // pages and reduce swapping while keeping the memory committed. |
| 1074 | // We page align to a conservative area inside the range to reset. |
| 1075 | bool _mi_os_reset(void* addr, size_t size, mi_stats_t* tld_stats) { |
| 1076 | MI_UNUSED(tld_stats); |
| 1077 | mi_stats_t* stats = &_mi_stats_main; |
| 1078 | return mi_os_resetx(addr, size, true, stats); |
| 1079 | } |
| 1080 | |
| 1081 | /* |
| 1082 | bool _mi_os_unreset(void* addr, size_t size, bool* is_zero, mi_stats_t* tld_stats) { |
no test coverage detected