Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Add support for arm64-apple and arm64-u*-linux #6108

Draft
wants to merge 17 commits into
base: master
Choose a base branch
from

Conversation

chevdor
Copy link
Contributor

@chevdor chevdor commented Oct 5, 2022

Until now, we are building only for x86_64-unknown-linux-gnu. This PR adds support for more targets.

This PR adds support for building binaries for:

  • aarch64-apple-darwin aka Apple Silicon M1 & Co.
  • aarch64-unknown-linux-gnu aka Linux/arm64

A first test showed that switching the global allocator for those works and produces a binary that does run on a M1 machine.

  • Build binary for M1 locally (Mac Intel)
  • Test M1 binary
  • Cross build M1 binary
  • Cross build for arm64
  • Test linux/arm64 binary

@github-actions github-actions bot added the A3-in_progress Pull request is in progress. No review needed at this stage. label Oct 5, 2022
@chevdor chevdor added B1-releasenotes C1-low PR touches the given topic and has a low impact on builders. labels Oct 5, 2022
@chevdor chevdor changed the title Add support for arm64 darwin and linux Add support for arm64-apple and arm64-u*-linux Jan 19, 2023
@chevdor
Copy link
Contributor Author

chevdor commented Jan 19, 2023

bot rebase

@paritytech-processbot
Copy link

Error: Command 'Command { std: "git" "merge" "origin/master" "--no-ff" "--no-edit", kill_on_drop: false }' failed with status Some(1); output: no output

@the-right-joyce the-right-joyce added B1-note_worthy Changes should be noted in the release notes and removed B1-releasenotes labels Jan 20, 2023
@chevdor
Copy link
Contributor Author

chevdor commented Jan 24, 2023

A quick update on this issue. I was able to cross-build a linux/arm64 binary and a quick test (qemu vm) showed promising results. I will now test on a real machine and go through a full sync.

@chevdor chevdor force-pushed the wk-221004-target-aarch64-apple-darwin branch from f902961 to 670934b Compare January 24, 2023 17:04
@chevdor chevdor added T0-node This PR/Issue is related to the topic “node”. T8-release This PR/Issue is related to topics touching the release notes. labels Jan 24, 2023
@chevdor chevdor force-pushed the wk-221004-target-aarch64-apple-darwin branch from 670934b to 2a92cd8 Compare February 1, 2023 10:07
Comment on lines +225 to +236

# x86_64-unknown-linux-gnu
[target.x86_64-unknown-linux-gnu.dependencies]
parity-util-mem = { version = "0.12", default-features = false, features = ["jemalloc-global"] }

# Apple Silicon chips
[target.aarch64-apple-darwin.dependencies]
parity-util-mem = { version = "0.12", default-features = false, features = ["mimalloc-global"] }

# linux/arm64
[target.aarch64-unknown-linux-gnu.dependencies]
parity-util-mem = { version = "0.12", default-features = false, features = ["mimalloc-global"] }
Copy link
Member

@ordian ordian Feb 1, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no longer needed on current master
are there jemalloc problems similar to #6591?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There were issues at runtime yes but I started this PR a while back.
I will check again master without those profiles, thanks for the notice.

@paritytech-cicd-pr
Copy link

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/polkadot/-/jobs/2360849

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A3-in_progress Pull request is in progress. No review needed at this stage. B1-note_worthy Changes should be noted in the release notes C1-low PR touches the given topic and has a low impact on builders. T0-node This PR/Issue is related to the topic “node”. T8-release This PR/Issue is related to topics touching the release notes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants