-
Notifications
You must be signed in to change notification settings - Fork 329
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
Add m1 support to conda build scripts #813
Conversation
There's no CI for this platform yet, but I tested this on my local M1. |
I guess the way to test this will be:
Finally: repeat for Numba and check if the M1 llvmdev&llvmlite combo is good for Numba too! |
Update: I tried to build this with
|
I should note that, using the miniconda for M1 distribution available here: https://docs.conda.io/en/latest/miniconda.html seems like the build is now going through. |
Ok, I managed to build this, next step will be to setup an M1 worker on our internal build farm and do a buildout there. |
I built a first artifact here: https://anaconda.org/numba/llvmdev/11.1.0/download/osx-arm64/llvmdev-11.1.0-h70deae4_5.tar.bz2 |
I can confirm I am able to build llvmdev for the correct architecture (m1) now. |
It took some trickeries with the code recipe and the specification of the correct llvmdev (M1 needs build 5). But apparently I made some llvmlite 0.39dev0 versions for https://anaconda.org/numba/llvmlite/files?version=0.39.0dev0 If anyone has spare cycles, it would be great if you could test these somehow. Even a plain installation check on an M1 would be useful. These packages are brand new and experimental and I fully anticipate there to be issues. So thank you in advance for any of your time that you can contribute. @seibert the following modifications had to be made to this patch, in order for llvmlite to build successfully: |
OK, the packages are available from the
And then test with:
|
@seibert I think we should cherry-pick my changes and then merge this PR. Having it on |
@seibert as per our OOB conversation, I have pushed: dbe6ea0 -- which is the patch to select the correct version of llvmdev (M1 needs 5) for llvmlite. Other than that, I think this is ready to review, there were a number of internal patches to the build farm, but we have taken care of those. If we can merge this to main, we will get a fresh set of llvmlite 0.39dev0 on I think that I have provided everything for a review, files and suggestions etc... If anything is missing let me know and I'll see what I can do. |
looks like Numba was build-able but had some issues itself: numba/numba#7822 |
I would hold off merging this until we are certain that no bugs in llvm/llvmlite need to be patched. |
I ran the test for llvm in Conda and it passed 😁 Here is what I saw:
My info: |
Thank you for confirming! |
Please let us know if there is anything else we could do to help. |
Thank you for offering to help. We are currently blocked by: numba/numba#7822 as we need to get Numba working on the M1 too. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the patch, few minor comments but looks good otherwise. Obviously this needs testing on the build farm etc!
@@ -54,7 +54,7 @@ requirements: | |||
host: | |||
# needed for llc at runtime | |||
- zlib # [not win] | |||
- xar # [osx] | |||
- xar # [osx and x86_64] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does OSX-arm64 not need xar
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The package doesn't exist in the package repository for this platform. I'm not entirely certain what it is for, and the tests seem to pass without it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess the question is... does llvm-objdump
work on M1, as from 73cf559 it seems like that was what triggered adding it. I suppose though that this is also somewhat moot if the package doesn't exist and further that this is a first build out on this architecture!
Co-authored-by: stuartarchibald <stuartarchibald@users.noreply.github.com>
Co-authored-by: stuartarchibald <stuartarchibald@users.noreply.github.com>
On Mar 15, 2022, at 10:04 AM, stuartarchibald ***@***.***> wrote:
@stuartarchibald commented on this pull request.
In conda-recipes/llvmdev/meta.yaml:
> @@ -54,7 +54,7 @@ requirements:
host:
# needed for llc at runtime
- zlib # [not win]
- - xar # [osx]
+ - xar # [osx and x86_64]
I guess the question is... does llvm-objdump work on M1, as from 73cf559 it seems like that was what triggered adding it. I suppose though that this is also somewhat moot if the package doesn't exist and further that this is a first build out on this architecture!
I have objdump on my M1 MacBook Air. Just tell me what you want to test I could test it out for you. I would suggest send me the options you want to test and any file you want me to test it on.
|
@stuartarchibald @seibert thank you for the review and updates. I am running this through the farm as I also checked |
This passed fine again. I am marking this as RTM now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the patch, testing and fixes! Looks good.
Many thanks @esc . |
Our build has completed, the files are now available in: https://anaconda.org/numba/llvmlite/files Development versions of llvmlite for M1 can now be installed on M1 too using:
|
Add m1 support to conda build scripts
Merge pull request #813 from seibert/m1_support
Minor adjustments needed to address differences in clang version and SDK version for osx-arm64.