]> git.proxmox.com Git - rustc.git/blame - compiler/rustc_target/src/spec/aarch64_unknown_none.rs
New upstream version 1.66.0+dfsg1
[rustc.git] / compiler / rustc_target / src / spec / aarch64_unknown_none.rs
CommitLineData
e74abb32 1// Generic AArch64 target for bare-metal code - Floating point enabled
b7449926
XL
2//
3// Can be used in conjunction with the `target-feature` and
4// `target-cpu` compiler flags to opt-in more hardware-specific
5// features.
6//
7// For example, `-C target-cpu=cortex-a53`.
8
2b03887a 9use super::{Cc, LinkerFlavor, Lld, PanicStrategy, RelocModel, Target, TargetOptions};
b7449926 10
29967ef6 11pub fn target() -> Target {
b7449926 12 let opts = TargetOptions {
2b03887a 13 linker_flavor: LinkerFlavor::Gnu(Cc::No, Lld::Yes),
5e7ed085
FG
14 linker: Some("rust-lld".into()),
15 features: "+strict-align,+neon,+fp-armv8".into(),
f9f354fc 16 relocation_model: RelocModel::Static,
b7449926 17 disable_redzone: true,
b7449926
XL
18 max_atomic_width: Some(128),
19 panic_strategy: PanicStrategy::Abort,
dfeec247 20 ..Default::default()
b7449926 21 };
29967ef6 22 Target {
5e7ed085 23 llvm_target: "aarch64-unknown-none".into(),
29967ef6 24 pointer_width: 64,
5e7ed085
FG
25 data_layout: "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".into(),
26 arch: "aarch64".into(),
b7449926 27 options: opts,
29967ef6 28 }
b7449926 29}