mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-07-06 19:38:41 +03:00
move mi_thread_id to primitives
This commit is contained in:
parent
4348a05d0f
commit
3579d3b861
4 changed files with 119 additions and 106 deletions
|
@ -6,6 +6,7 @@ terms of the MIT license. A copy of the license can be found in the file
|
|||
-----------------------------------------------------------------------------*/
|
||||
#include "mimalloc.h"
|
||||
#include "mimalloc-internal.h"
|
||||
#include "prim/prim.h"
|
||||
|
||||
#include <string.h> // memcpy, memset
|
||||
#include <stdlib.h> // atexit
|
||||
|
@ -103,6 +104,10 @@ mi_decl_cache_align const mi_heap_t _mi_heap_empty = {
|
|||
};
|
||||
|
||||
|
||||
mi_threadid_t _mi_thread_id(void) mi_attr_noexcept {
|
||||
return _mi_prim_thread_id();
|
||||
}
|
||||
|
||||
// the thread-local default heap for allocation
|
||||
mi_decl_thread mi_heap_t* _mi_heap_default = (mi_heap_t*)&_mi_heap_empty;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue