]> git.lizzy.rs Git - rust.git/blob - compiler/rustc_target/src/spec/aarch64_apple_ios_macabi.rs
Auto merge of #97800 - pnkfelix:issue-97463-fix-aarch64-call-abi-does-not-zeroext...
[rust.git] / compiler / rustc_target / src / spec / aarch64_apple_ios_macabi.rs
1 use super::apple_sdk_base::{opts, Arch};
2 use crate::spec::{FramePointer, LinkerFlavor, Target, TargetOptions};
3
4 pub fn target() -> Target {
5     let llvm_target = "arm64-apple-ios14.0-macabi";
6
7     let mut base = opts("ios", Arch::Arm64_macabi);
8     base.add_pre_link_args(LinkerFlavor::Gcc, &["-target", llvm_target]);
9
10     Target {
11         llvm_target: llvm_target.into(),
12         pointer_width: 64,
13         data_layout: "e-m:o-i64:64-i128:128-n32:64-S128".into(),
14         arch: "aarch64".into(),
15         options: TargetOptions {
16             features: "+neon,+fp-armv8,+apple-a12".into(),
17             max_atomic_width: Some(128),
18             forces_embed_bitcode: true,
19             frame_pointer: FramePointer::NonLeaf,
20             // Taken from a clang build on Xcode 11.4.1.
21             // These arguments are not actually invoked - they just have
22             // to look right to pass App Store validation.
23             bitcode_llvm_cmdline: "-triple\0\
24                 arm64-apple-ios14.0-macabi\0\
25                 -emit-obj\0\
26                 -disable-llvm-passes\0\
27                 -Os\0"
28                 .into(),
29             ..base
30         },
31     }
32 }