Skip to content

improve MacOS interposes to make mimalloc compile for older MacOS #1028

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

Noxybot
Copy link

@Noxybot Noxybot commented Mar 6, 2025

I've got a failure while trying to compile with "-mmacosx-version-min=10.7" since MAC_OS_X_VERSION_MAX_ALLOWED is greater than MAC_OS_X_VERSION_10_15 but still we can't use aligned_alloc since of the lower bound (10.7). I'm not sure about internal details of how __OSX_AVAILABLE works, but my hope is the it would only make this interpose available starting from the OS version specified. Also, it helps me to compile mimalloc with "-mmacosx-version-min=10.7".

I've got a failure while trying to compile with "-mmacosx-version-min=10.7" since MAC_OS_X_VERSION_MAX_ALLOWED is greater than MAC_OS_X_VERSION_10_15 but still we can't use `aligned_alloc` since of the lower bound (10.7).
I'm not sure about internal details of how `__OSX_AVAILABLE` works, but my hope is the it would only make this interpose available starting from the OS version specified.
Also, it helps me to compile mimalloc with "-mmacosx-version-min=10.7".
@Noxybot
Copy link
Author

Noxybot commented Mar 31, 2025

Hey @daanx - could you check this change once again, please?
It makes some interposes more robust (so they are always present when available rather than excluded depending on target MacOS version that mimalloc is compiled for).
I've been running both dev2 and dev3 with this change locally for quite some time (and mimalloc seems to not work without it in our environment).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant