Skip to content

Conversation

@jonathanpallant
Copy link
Contributor

This PR adds checks to the aarch64v8r-unknown-none target to verify that if the Cortex-R82 CPU is enabled (with -Ctarget-cpu=cortex-r82), that the appropriate additional AArch64 features are enabled.

This is important because Cortex-R82 is (currently) the only processor implementing Armv8-R AArch64 and it implements a number of Armv8 features over and above the baseline for the architecture. Many of these features are of interest to safety-critical firmware development (for example FEAT_RASv1p1, which adds support for the RAS Common Fault Injection Model Extension) and so we anticipate them being enabled when building such firmware.

We are offering these tests upstream in-lieu of a full Cortex-R82 specific target because we understand the Project has a preference for architecture-baseline targets over CPU-specific targets.

This PR builds on and requires #150863, but we've pulled them out as a separate PR.

Ownership

This PR was developed by Ferrous Systems on behalf of Arm. Arm is the owner of these changes.

@rustbot
Copy link
Collaborator

rustbot commented Jan 19, 2026

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

cc @Noratrieb

Some changes occurred in tests/codegen-llvm/sanitizer

cc @rcvalle

@rustbot rustbot added A-tidy Area: The tidy tool PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Jan 19, 2026
@rustbot
Copy link
Collaborator

rustbot commented Jan 19, 2026

r? @BoxyUwU

rustbot has assigned @BoxyUwU.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@BoxyUwU
Copy link
Member

BoxyUwU commented Jan 20, 2026

r? compiler

@rustbot rustbot assigned fee1-dead and unassigned BoxyUwU Jan 20, 2026
@rust-bors

This comment has been minimized.

jonathanpallant and others added 5 commits January 22, 2026 15:48
…8r-unknown-none-softfloat`.

The existing `aarch64-unknown-none` target assumes Armv8.0-A as a baseline. However, Arm recently released the Arm Cortex-R82 processor which is the first to implement the Armv8-R AArch64 mode architecture. This architecture is similar to Armv8-A AArch64, however it has a different set of mandatory features, and is based off of Armv8.4. It is largely unrelated to the existing Armv8-R architecture target (`armv8r-none-eabihf`), which only operates in AArch32 mode.

The second `aarch64v8r-unknown-none-softfloat` target allows for possible Armv8-R AArch64 CPUs with no FPU, or for use-cases where FPU register stacking is not desired. As with the existing `aarch64-unknown-none` target we have coupled FPU support and Neon support together - there is no 'has FPU but does not have NEON' target proposed even though the architecture technically allows for it.

This PR was developed by Ferrous Systems on behalf of Arm. Arm is the owner of these changes.
- line wrapping
- extend the mapping of target_arch to llvm_component in tidy itself so it can
  handle target tuples that start with an aarch64v8r component
- fix needs-llvm-component directive in `aarch64v8r` UI assembly test
- extend `tests/assembly-llvm/targets/targets-elf.rs` as per target policy check
This PR adds checks to the `aarch64v8r-unknown-none` target to verify that if the Cortex-R82 CPU is enabled (with `-Ctarget-cpu=cortex-r82`), that the appropriate additional AArch64 features are enabled.

This is important because Cortex-R82 is (currently) the only processor implementing Armv8-R AArch64 and it implements a number of Armv8 features over and above the baseline for the architecture. Many of these features are of interest to safety-critical firmware development (for example `FEAT_RASv1p1`, which adds support for the *RAS Common Fault Injection Model Extension*) and so we anticipate them being enabled when building such firmware.

We are offering these tests upstream in-lieu of a full Cortex-R82 specific target because we understand the Project has a preference for architecture-baseline targets over CPU-specific targets.

This PR builds on and requires rust-lang#150863, but we've pulled them out as a separate PR.

This PR was developed by Ferrous Systems on behalf of Arm. Arm is the owner of these changes.
@rustbot
Copy link
Collaborator

rustbot commented Jan 22, 2026

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-tidy Area: The tidy tool PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants