Skip to content

workflow/build: Setup QEMU, add builds aarch64 on Linux, arm64 on MacOS#37

Closed
uSpike wants to merge 1 commit into
mypyc:masterfrom
uSpike:build-aarch64-wheels
Closed

workflow/build: Setup QEMU, add builds aarch64 on Linux, arm64 on MacOS#37
uSpike wants to merge 1 commit into
mypyc:masterfrom
uSpike:build-aarch64-wheels

Conversation

@uSpike

@uSpike uSpike commented Jun 1, 2022

Copy link
Copy Markdown

Work-in-progress

Closes: #12

@uSpike

uSpike commented Jun 1, 2022

Copy link
Copy Markdown
Author

Could someone please approve the workflow?

@uSpike

uSpike commented Jun 1, 2022

Copy link
Copy Markdown
Author

Working on this in uSpike#1 - don't need workflow approval

@uSpike
uSpike force-pushed the build-aarch64-wheels branch from 5e4b6b3 to 5e0c9f0 Compare August 5, 2022 15:38
@uSpike
uSpike force-pushed the build-aarch64-wheels branch from 7ead7cb to 8970572 Compare August 5, 2022 16:44
@uSpike uSpike changed the title Draft: workflow/build: Setup QEMU and build auto+aarch64 wheels workflow/build: Setup QEMU, add builds aarch64 on Linux, arm64 on MacOS Aug 5, 2022
@uSpike

uSpike commented Aug 5, 2022

Copy link
Copy Markdown
Author

I've modified this to be explicit about the CIBW_ARCH for each OS/python version matrix. It adds builds for aarch64 on Linux, arm64 on MacOS and does them in separate workflows for speed.

@uSpike

uSpike commented Aug 5, 2022

Copy link
Copy Markdown
Author

@hauntsaninja would super appreciate a workflow approval if you could!

@hauntsaninja

hauntsaninja commented Aug 6, 2022

Copy link
Copy Markdown
Collaborator

Thanks for attempting this!

Unfortunately, I think emulation is just too slow. The linux builds are timing out after six hours and it barely even made it to the musllinux stuff. I don’t think we’d want builds to take much longer than they already do — it makes releasing mypy a huge pain if you have to wait a substantial fraction of a day to get a candidate build. (As it is, I suspect the musllinux stuff might need to be splintered into their own jobs or removed or something too)

This good news is this isn’t critical for users, since mypy ships pure Python wheels. I’ll also note that we currently cross compile and ship arm64 wheels for macOS (e.g. so the macOS changes in this PR aren’t necessary).

@achimnol

achimnol commented Sep 11, 2023

Copy link
Copy Markdown
Contributor

@hauntsaninja @uSpike I have tested the manylinux-aarch64 build on an Applie Silicon (M1 Max) with Orbstack-based Ubuntu 22.04 VM (RAM 16GB allocated). It runs well, and the build takes about two hours, similarly to the x86 builds in this repository's action logs.
https://github.com/lablup/backend.ai-oven/tree/main/pypi/projects/mypy

The performance improvement is almost 3x (32s → 10s) using these wheels on my prepo (https://github.com/lablup/backend.ai) where more than 600 files need to be checked. I think it would be really nice to have an official linux-aarch64 wheel builds.

Maybe could we workaround the performance issue by using macOS arm64 runners with a linux-aarch64 VM?

@christianbundy

Copy link
Copy Markdown
Contributor

maybe relevant: pypa/cibuildwheel#598

@christianbundy

Copy link
Copy Markdown
Contributor

@hauntsaninja sorry to bump this, but I figured it's more polite than opening a new [duplicate] issue: would you be open to having aarch64 added with fewer tests run (similar to maco-arm64)? I've got it working and I'm happy to open a PR too if that's easier.

@hauntsaninja

hauntsaninja commented Jan 25, 2024

Copy link
Copy Markdown
Collaborator

Feel free to open a PR, but no promises that I'll merge, in particular I probably won't if the build takes much longer than an hour.

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.

Build Aarch64 manylinux wheels

4 participants