Skip to content
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 target docs for aarch64-apple-darwin (M1/M2 macs) #124134

Closed
wants to merge 8 commits into from

Conversation

TimTheBig
Copy link

@TimTheBig TimTheBig commented Apr 18, 2024

Add target documentation for aarch64-apple-darwin; 64-bit ARM-based macs running macOS, specifically Macs with "M" series Apple Silicon chips.
"M" series macs are quite popular so it would be useful to have some docs.

@rustbot
Copy link
Collaborator

rustbot commented Apr 18, 2024

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @GuillaumeGomez (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Apr 18, 2024
@rustbot
Copy link
Collaborator

rustbot commented Apr 18, 2024

Some changes occurred in src/doc/rustc/src/platform-support

cc @Nilstrieb

@GuillaumeGomez
Copy link
Member

r? Nilstrieb

@rustbot rustbot assigned Noratrieb and unassigned GuillaumeGomez Apr 18, 2024
@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-llvm-17 failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
#16 exporting to docker image format
#16 sending tarball 30.7s done
#16 DONE 36.0s
##[endgroup]
Setting extra environment values for docker:  --env ENABLE_GCC_CODEGEN=1 --env GCC_EXEC_PREFIX=/usr/lib/gcc/
[CI_JOB_NAME=x86_64-gnu-llvm-17]
---
sccache: Starting the server...
##[group]Configure the build
configure: processing command line
configure: 
configure: build.configure-args := ['--build=x86_64-unknown-linux-gnu', '--llvm-root=/usr/lib/llvm-17', '--enable-llvm-link-shared', '--set', 'rust.thin-lto-import-instr-limit=10', '--set', 'change-id=99999999', '--enable-verbose-configure', '--enable-sccache', '--disable-manage-submodules', '--enable-locked-deps', '--enable-cargo-native-static', '--set', 'rust.codegen-units-std=1', '--set', 'dist.compression-profile=balanced', '--dist-compression-formats=xz', '--disable-dist-src', '--release-channel=nightly', '--enable-debug-assertions', '--enable-overflow-checks', '--enable-llvm-assertions', '--set', 'rust.verify-llvm-ir', '--set', 'rust.codegen-backends=llvm,cranelift,gcc', '--set', 'llvm.static-libstdcpp', '--enable-new-symbol-mangling']
configure: target.x86_64-unknown-linux-gnu.llvm-config := /usr/lib/llvm-17/bin/llvm-config
configure: llvm.link-shared     := True
configure: rust.thin-lto-import-instr-limit := 10
configure: change-id            := 99999999
---
  Downloaded boml v0.3.1
   Compiling boml v0.3.1
   Compiling y v0.1.0 (/checkout/compiler/rustc_codegen_gcc/build_system)
    Finished `release` profile [optimized] target(s) in 3.62s
     Running `/checkout/obj/build/x86_64-unknown-linux-gnu/stage1-codegen/x86_64-unknown-linux-gnu/release/y test --use-system-gcc --use-backend gcc --out-dir /checkout/obj/build/x86_64-unknown-linux-gnu/stage1-tools/cg_gcc --release --mini-tests --std-tests`
Using system GCC
[BUILD] example
[AOT] mini_core_hello_world
/checkout/obj/build/x86_64-unknown-linux-gnu/stage1-tools/cg_gcc/mini_core_hello_world
abc
---
##[group]Building stage0 tool linkchecker (x86_64-unknown-linux-gnu)
    Finished `release` profile [optimized] target(s) in 0.12s
##[endgroup]
##[group]Testing stage0 Linkcheck (x86_64-unknown-linux-gnu)
rustc/print.html:8743: broken link - `rustc/platform-support/aarch64-apple-darwin.html`
rustc/platform-support.html:249: broken link - `rustc/platform-support/aarch64-apple-darwin.html`
number of HTML files scanned: 38227
number of HTML redirects found: 12079
number of links checked: 3071877
number of links ignored due to external: 73231

Comment on lines +23 to +25
Just add it to the `target` with:
```sh
rustup target add aarch64-apple-darwin
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this section is supposed to be for building rustc such that it includes the target, not just for building code that uses the target. Although looking at the other documents it's kind of inconsistently used?

Copy link
Author

Choose a reason for hiding this comment

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

The command for building the target std is always the same, so I think this should be fine.

@pthariensflame
Copy link
Contributor

@rustbot label O-macos O-AArch64 A-docs

@rustbot rustbot added A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools O-AArch64 Armv8-A or later processors in AArch64 mode O-macos Operating system: macOS labels Apr 21, 2024
@pthariensflame
Copy link
Contributor

#124146 may be useful to note?

@madsmtm
Copy link
Contributor

madsmtm commented May 5, 2024

I've documented this target (and more) in #124772 too.

@TimTheBig
Copy link
Author

TimTheBig commented May 5, 2024

I've documented this target (and more) in #124772 too.

Nice 👍, @madsmtm, do you want to add this aarch64 doc to that pull.
edit: I misread, your docs do have aarch64 in them.

@madsmtm
Copy link
Contributor

madsmtm commented May 6, 2024

do you want to add this aarch64 doc to that pull.

Hmm, not sure what you mean by that? I've added documentation about it to the more general platform-support/apple-darwin.md file which also documents x86_64-apple-darwin.

@TimTheBig
Copy link
Author

My mistake I misread. Your docs are good so I will close this pull, I look foreword to reading the new pages.

@TimTheBig TimTheBig closed this May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools O-AArch64 Armv8-A or later processors in AArch64 mode O-macos Operating system: macOS S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants