diff options
author | Daan <daanl@outlook.com> | 2022-04-08 14:44:35 -0700 |
---|---|---|
committer | Daan <daanl@outlook.com> | 2022-04-08 14:44:35 -0700 |
commit | 862f07bc7662b1788193027e98a4d4b572bbcaef (patch) | |
tree | eaa0d6e4ede88be73e440b292e4362da16eb1074 /src/os.c | |
parent | 131b62283b6a58971e48c4521399dcb99004187f (diff) | |
parent | 674ee63fa741449d348b277eef6d06c268c6f925 (diff) |
Merge branch 'dev' into dev-slice
Diffstat (limited to 'src/os.c')
-rw-r--r-- | src/os.c | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -97,7 +97,7 @@ bool _mi_os_has_overcommit(void) { } // OS (small) page size -size_t _mi_os_page_size() { +size_t _mi_os_page_size(void) { return os_page_size; } @@ -149,7 +149,7 @@ static PGetCurrentProcessorNumberEx pGetCurrentProcessorNumberEx = NULL; static PGetNumaProcessorNodeEx pGetNumaProcessorNodeEx = NULL; static PGetNumaNodeProcessorMaskEx pGetNumaNodeProcessorMaskEx = NULL; -static bool mi_win_enable_large_os_pages() +static bool mi_win_enable_large_os_pages(void) { if (large_os_page_size > 0) return true; @@ -220,7 +220,7 @@ void _mi_os_init(void) } } #elif defined(__wasi__) -void _mi_os_init() { +void _mi_os_init(void) { os_overcommit = false; os_page_size = 64*MI_KiB; // WebAssembly has a fixed page size: 64KiB os_alloc_granularity = 16; @@ -251,7 +251,7 @@ static void os_detect_overcommit(void) { #endif } -void _mi_os_init() { +void _mi_os_init(void) { // get the page size long result = sysconf(_SC_PAGESIZE); if (result > 0) { @@ -1291,7 +1291,7 @@ void _mi_os_free_huge_pages(void* p, size_t size, mi_stats_t* stats) { Support NUMA aware allocation -----------------------------------------------------------------------------*/ #ifdef _WIN32 -static size_t mi_os_numa_nodex() { +static size_t mi_os_numa_nodex(void) { USHORT numa_node = 0; if (pGetCurrentProcessorNumberEx != NULL && pGetNumaProcessorNodeEx != NULL) { // Extended API is supported |