]> git.proxmox.com Git - rustc.git/blame - compiler/rustc_target/src/spec/aarch64_unknown_none_softfloat.rs
New upstream version 1.66.0+dfsg1
[rustc.git] / compiler / rustc_target / src / spec / aarch64_unknown_none_softfloat.rs
CommitLineData
e74abb32
XL
1// Generic AArch64 target for bare-metal code - Floating point disabled
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};
e74abb32 10
29967ef6 11pub fn target() -> Target {
e74abb32 12 let opts = TargetOptions {
5e7ed085 13 abi: "softfloat".into(),
2b03887a 14 linker_flavor: LinkerFlavor::Gnu(Cc::No, Lld::Yes),
5e7ed085
FG
15 linker: Some("rust-lld".into()),
16 features: "+strict-align,-neon,-fp-armv8".into(),
f9f354fc 17 relocation_model: RelocModel::Static,
e74abb32 18 disable_redzone: true,
e74abb32
XL
19 max_atomic_width: Some(128),
20 panic_strategy: PanicStrategy::Abort,
dfeec247 21 ..Default::default()
e74abb32 22 };
29967ef6 23 Target {
5e7ed085 24 llvm_target: "aarch64-unknown-none".into(),
29967ef6 25 pointer_width: 64,
5e7ed085
FG
26 data_layout: "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".into(),
27 arch: "aarch64".into(),
e74abb32 28 options: opts,
29967ef6 29 }
e74abb32 30}