|
| 1 | +use super::apple_base::{opts, tvos_sim_llvm_target, Arch}; |
| 2 | +use crate::spec::{FramePointer, SanitizerSet, Target, TargetOptions}; |
| 3 | + |
| 4 | +pub fn target() -> Target { |
| 5 | + let arch = Arch::Arm64_sim; |
| 6 | + let mut base = opts("ios", arch); |
| 7 | + base.supported_sanitizers = SanitizerSet::ADDRESS | SanitizerSet::THREAD; |
| 8 | + Target { |
| 9 | + llvm_target: tvos_sim_llvm_target(arch).into(), |
| 10 | + pointer_width: 64, |
| 11 | + data_layout: "e-m:o-i64:64-i128:128-n32:64-S128".into(), |
| 12 | + arch: arch.target_arch(), |
| 13 | + options: TargetOptions { |
| 14 | + features: "+neon,+fp-armv8,+apple-a7".into(), |
| 15 | + max_atomic_width: Some(128), |
| 16 | + forces_embed_bitcode: true, |
| 17 | + frame_pointer: FramePointer::NonLeaf, |
| 18 | + // Taken from (and slightly modified) the aarch64-apple-ios-sim spec which says: |
| 19 | + // Taken from a clang build on Xcode 11.4.1. |
| 20 | + // These arguments are not actually invoked - they just have |
| 21 | + // to look right to pass App Store validation. |
| 22 | + bitcode_llvm_cmdline: "-triple\0\ |
| 23 | + arm64-apple-tvos14.0-simulator\0\ |
| 24 | + -emit-obj\0\ |
| 25 | + -disable-llvm-passes\0\ |
| 26 | + -target-abi\0\ |
| 27 | + darwinpcs\0\ |
| 28 | + -Os\0" |
| 29 | + .into(), |
| 30 | + ..base |
| 31 | + }, |
| 32 | + } |
| 33 | +} |
0 commit comments