Skip to content

Add linux_aarch64 platform#76

Merged
hauntsaninja merged 4 commits into
mypyc:masterfrom
christianbundy:christian/linux_aarch64
Dec 28, 2024
Merged

Add linux_aarch64 platform#76
hauntsaninja merged 4 commits into
mypyc:masterfrom
christianbundy:christian/linux_aarch64

Conversation

@christianbundy

@christianbundy christianbundy commented Feb 6, 2024

Copy link
Copy Markdown
Contributor

Problem

We aren't building wheels for linux_aarch64, which is a commonly used architecture. For example, when using Docker on an Apple M1 Pro:

$ docker run ubuntu uname -sm
Linux aarch64

Solution

Add aarch64 to CIBW_ARCHS_LINUX, add QEMU for emulation, and add an override to cibuildwheel.toml that runs only testcheck. This takes about 90 minutes for manylinux and 2 hours for musllinux.


See-also: #37

@achimnol

achimnol commented Jun 6, 2024

Copy link
Copy Markdown
Contributor

@christianbundy @hauntsaninja Now we have native arm64 GitHub Actions runners for Ubuntu and Windows.
https://github.blog/2024-06-03-arm64-on-github-actions-powering-faster-more-efficient-build-systems/
This requires the large github runners setup in the repository or organization. Once done, this PR could avoid using the qemu action but use the native arm64 runner.

@komapa

komapa commented Jul 22, 2024

Copy link
Copy Markdown

Hello, is this closer to being merged? Thank you!

@cdce8p

cdce8p commented Dec 23, 2024

Copy link
Copy Markdown
Contributor

Looking at the PyPI download stats, I also think it would make sense to add wheels for aarch64.

It's a bit unfortunate that the build takes so much longer than any of the other platforms. Maybe we should only build manylinux_aarch64 for now? @hauntsaninja What do you think?

When Github finally makes ARM runners available for free plans as well, we could reconsider that. github/roadmap#970

pypinfo -pc --days 28 --all --limit 20 \
    --where 'details.cpu != "None"' 'mypy==1.13.*' system cpu libc
system_name cpu libc_name percent download_count Wheels
Linux x86_64 glibc 89.63% 12,154,910 x
Windows AMD64 None 3.65% 494,638 x
Linux aarch64 glibc 2.69% 364,335 <--
Darwin arm64 None 2.03% 275,469 x
Linux x86_64 None 1.07% 145,756 x
Darwin x86_64 None 0.53% 71,899 x
Linux x86_64 musl 0.30% 41,083 x
Linux aarch64 None 0.05% 7,371
Linux i686 glibc 0.02% 2,045
Linux s390x glibc 0.01% 748
Linux aarch64 musl 0.00% 677
Linux ppc64le glibc 0.00% 601

@hauntsaninja

hauntsaninja commented Dec 28, 2024

Copy link
Copy Markdown
Collaborator

Thanks for the data. It does look like the musllinux aarch64 wheels are over two hours, which is much slower than even the manylinux aarch64 wheels, and benefits 0.00% of users. Pushed a commit dropping them. After that, we can merge and see. Worst case we revert and wait for Github to ship ARM runners.

@hauntsaninja hauntsaninja merged commit 4d92335 into mypyc:master Dec 28, 2024
@christianbundy

Copy link
Copy Markdown
Contributor Author

Good call, thanks! Looking forward to checking out the impact here.

@cdce8p

cdce8p commented Dec 30, 2024

Copy link
Copy Markdown
Contributor

Good call, thanks! Looking forward to checking out the impact here.

Mypy 1.14.1 just shipped with manylinux_aarch64 wheels.
https://pypi.org/project/mypy/1.14.1/#files

@achimnol

achimnol commented Jan 2, 2025

Copy link
Copy Markdown
Contributor

Finally!!!! 🎉

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.

5 participants