mirror of
https://github.com/microsoft/mimalloc.git
synced 2025-05-06 15:29:31 +03:00
Change macOS mmap tag to fix conflict with IOAccelerator
Tag 100 is assigned to "IOAccelerator" (the GPU driver stack on Apple silicon), which makes for confusing output when debugging.
To avoid conflicts, use a tag in the reserved application-specific range from 240–255 (inclusive).
All assigned tags: 94d3b45284/osfmk/mach/vm_statistics.h (L773-L775)
This commit is contained in:
parent
03020fbf81
commit
e8b5e51b00
1 changed files with 1 additions and 1 deletions
|
@ -240,7 +240,7 @@ static int unix_mmap_fd(void) {
|
||||||
#if defined(VM_MAKE_TAG)
|
#if defined(VM_MAKE_TAG)
|
||||||
// macOS: tracking anonymous page with a specific ID. (All up to 98 are taken officially but LLVM sanitizers had taken 99)
|
// macOS: tracking anonymous page with a specific ID. (All up to 98 are taken officially but LLVM sanitizers had taken 99)
|
||||||
int os_tag = (int)mi_option_get(mi_option_os_tag);
|
int os_tag = (int)mi_option_get(mi_option_os_tag);
|
||||||
if (os_tag < 100 || os_tag > 255) { os_tag = 100; }
|
if (os_tag < 100 || os_tag > 255) { os_tag = 254; }
|
||||||
return VM_MAKE_TAG(os_tag);
|
return VM_MAKE_TAG(os_tag);
|
||||||
#else
|
#else
|
||||||
return -1;
|
return -1;
|
||||||
|
|
Loading…
Add table
Reference in a new issue