Skip to content

BLD: Win-arm64 cross compile workflow #27330

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

Merged
merged 1 commit into from
Sep 6, 2024

Conversation

SlobodanMiletic
Copy link
Contributor

This PR is for the first stage of the Numpy win arm64 whl build. It is producing whl without openblas support. Second stage will be adding cross compilation step for openblas and building numpy with it.

PR Notes:

  • Most of the script work is written for powershell.
  • MSVC toolchain is used
  • For now step for uploading the wheel is commented out, but if needed when everything starts working it can be uncommented
  • For now workflow can be started only manually but if needed additional triggers can be added
  • Due to problems with cross compilation support this build is slightly improvised. For numpy code meson cross compile mechanism is used. However when linking with python dev libraries there are problems with platform mismatch. To go around this issue step is added to overwrite regular python x64 dev libraries in python libs folder with arm64 libraries fetched from nuget.
    Also as python x64 is used to drive the build, libraries from the wheel will have win_amd64 suffix. To fix that after the build whl is unpacked, files are renamed, meta data is changed, and the whl is packed again.
  • Produced whl is tested on arm64 machine

@melissawm melissawm added the 36 - Build Build related PR label Sep 4, 2024
@charris charris merged commit d9e101d into numpy:main Sep 6, 2024
67 checks passed
@charris
Copy link
Member

charris commented Sep 6, 2024

Thanks @SlobodanMiletic, might as well get this started.

@rgommers
Copy link
Member

rgommers commented Nov 5, 2024

For now workflow can be started only manually but if needed additional triggers can be added

I just noticed this PR (nice work!) and that the merged job has never been run on main. So I just triggered it, and it still passes. It's not slow (~8 min) so it makes sense to me to run it as a regular CI job on PRs. That will help us catch regressions. WDYT @SlobodanMiletic?

@charris charris changed the title Win-arm64 cross compile workflow CI: Win-arm64 cross compile workflow Nov 20, 2024
@charris charris changed the title CI: Win-arm64 cross compile workflow BLD: Win-arm64 cross compile workflow Nov 20, 2024
@HinTak
Copy link
Contributor

HinTak commented Apr 20, 2025

It takes 13 minutes on a folk I just run. I was hoping that just switching run-on to the new `windows-11-arm" runner would work, but it does not work that way.

Aarch64 linux does - I can switch 'aarch64 linux on x64 linux" to "aarch64 linux on aarch64 linux (different distro/version)" with a substantial speed up (like 10x to 25x).

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

Successfully merging this pull request may close these issues.

5 participants