-
Notifications
You must be signed in to change notification settings - Fork 674
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
Check before removing march=native #476
Conversation
From my understanding this is even worse as it removes the option overall to omit |
@xhochy |
We need a general switch to disable march=native as otherwise the binaries are no longer redistributable. The linked PR removes that possibility completely. The PR here only fixed this option for the corner case of Apple Silicon. |
@xhochy Can you provide more details about this problem? |
These runtime checks are useful for code where you explicitly use AVX & co. The problem with In the case of conda-forge, we build packages on Azure Pipelines where normally all the latest instruction sets are available but the users of the packages have older CPUs and not necessarily access to the latest AVX512 features. Thus binaries compiled with |
@xhochy thank you, it makes sense I think we can add Lines 81 to 82 in 6f2c82d
and a check if not os.environ.get("HNSWLIB_NO_NATIVE"): herehttps://github.com/nmslib/hnswlib/blob/develop/setup.py#L100-L114 |
If you set
HNSWLIB_NO_NATIVE
and build on Apple M1 the removal ofmarch=native
fails because it isn't in the list of arguments.