This repository contains code examples for the Ferrocene-exclusive
compilation target: aarch64r82-unknown-none,
Arm Cortex-R82 bare-metal (hard-float)
-
A Ferrocene toolchain license
-
Criticalup, Ferrocene's toolchain manager
-
Arm's Fixed Virtual Platform (FVP) Architecture Envelope Model (AEM) Base R, AKA
FVP_BaseR_AEMv8R1, which is free to useThe FVP is used to execute the examples. Ensure that it's part of your
$PATH. Version 'Fast Models [11.30.27 (Nov 14 2025)]' has been tested.
- (Optionally) Arm's Fixed Virtual Platform (FVP) Cortex-R models, like
FVP_BaseR_Cortex-R822, which requires a license
Run the following command to install the required Ferrocene components:
$ criticalup installCheck out git submodules:
$ git submodule update --initThese examples target the Armv8-R AArch64 ISA which is compatible with the Cortex-R82 ISA.
Prior to running any example, set the following environment variable from the root of this repository:
To run the examples on the AEM FVP:
$ export CARGO_TARGET_AARCH64R82_UNKNOWN_NONE_RUNNER="FVP_BaseR_AEMv8R -f $(pwd)/FVP_BaseR_AEMv8R.cfg"Or, to run the examples on the Cortex-R82 FVP:
$ export CARGO_TARGET_AARCH64R82_UNKNOWN_NONE_RUNNER="FVP_BaseR_Cortex-R82 -f $(pwd)/FVP_BaseR_Cortex-R82.cfg"Or configure the runner for the aarch64r82-unknown-none target in
the .cargo/config.toml file.
You must also comment out the [unstable] section in .cargo/config.toml so
that the libcore shipped with Ferrocene is used.
Change directory to aarch64-cpu/examples/armv8-r and follow the instructions in
the README file contained in that directory.
Whenever instructed to execute cargo run, run instead
criticalup run cargo run --target aarch64r82-unknown-none.
Licensed under either MIT or Apache-2.0 at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you shall be licensed as above, without any additional terms or conditions.