Move outline-atomics to aarch64-linux target definitions
This commit is contained in:
parent
1d04577ee0
commit
c9567e2424
6 changed files with 9 additions and 6 deletions
|
@ -406,11 +406,6 @@ pub fn llvm_global_features(sess: &Session) -> Vec<String> {
|
||||||
// -Ctarget-features
|
// -Ctarget-features
|
||||||
features.extend(sess.opts.cg.target_feature.split(',').flat_map(&filter));
|
features.extend(sess.opts.cg.target_feature.split(',').flat_map(&filter));
|
||||||
|
|
||||||
// FIXME: Move outline-atomics to target definition when earliest supported LLVM is 12.
|
|
||||||
if get_version() >= (12, 0, 0) && sess.target.llvm_target.contains("aarch64-unknown-linux") {
|
|
||||||
features.push("+outline-atomics".to_string());
|
|
||||||
}
|
|
||||||
|
|
||||||
features
|
features
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -8,6 +8,7 @@ pub fn target() -> Target {
|
||||||
data_layout: "E-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".to_string(),
|
data_layout: "E-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".to_string(),
|
||||||
arch: "aarch64".to_string(),
|
arch: "aarch64".to_string(),
|
||||||
options: TargetOptions {
|
options: TargetOptions {
|
||||||
|
features: "+outline-atomics".to_string(),
|
||||||
max_atomic_width: Some(128),
|
max_atomic_width: Some(128),
|
||||||
mcount: "\u{1}_mcount".to_string(),
|
mcount: "\u{1}_mcount".to_string(),
|
||||||
endian: Endian::Big,
|
endian: Endian::Big,
|
||||||
|
|
|
@ -12,6 +12,7 @@ pub fn target() -> Target {
|
||||||
arch: "aarch64".to_string(),
|
arch: "aarch64".to_string(),
|
||||||
options: TargetOptions {
|
options: TargetOptions {
|
||||||
abi: "ilp32".to_string(),
|
abi: "ilp32".to_string(),
|
||||||
|
features: "+outline-atomics".to_string(),
|
||||||
mcount: "\u{1}_mcount".to_string(),
|
mcount: "\u{1}_mcount".to_string(),
|
||||||
endian: Endian::Big,
|
endian: Endian::Big,
|
||||||
..base
|
..base
|
||||||
|
|
|
@ -7,6 +7,7 @@ pub fn target() -> Target {
|
||||||
data_layout: "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".to_string(),
|
data_layout: "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".to_string(),
|
||||||
arch: "aarch64".to_string(),
|
arch: "aarch64".to_string(),
|
||||||
options: TargetOptions {
|
options: TargetOptions {
|
||||||
|
features: "+outline-atomics".to_string(),
|
||||||
mcount: "\u{1}_mcount".to_string(),
|
mcount: "\u{1}_mcount".to_string(),
|
||||||
max_atomic_width: Some(128),
|
max_atomic_width: Some(128),
|
||||||
supported_sanitizers: SanitizerSet::ADDRESS
|
supported_sanitizers: SanitizerSet::ADDRESS
|
||||||
|
|
|
@ -8,6 +8,7 @@ pub fn target() -> Target {
|
||||||
arch: "aarch64".to_string(),
|
arch: "aarch64".to_string(),
|
||||||
options: TargetOptions {
|
options: TargetOptions {
|
||||||
abi: "ilp32".to_string(),
|
abi: "ilp32".to_string(),
|
||||||
|
features: "+outline-atomics".to_string(),
|
||||||
max_atomic_width: Some(128),
|
max_atomic_width: Some(128),
|
||||||
mcount: "\u{1}_mcount".to_string(),
|
mcount: "\u{1}_mcount".to_string(),
|
||||||
..super::linux_gnu_base::opts()
|
..super::linux_gnu_base::opts()
|
||||||
|
|
|
@ -9,6 +9,10 @@ pub fn target() -> Target {
|
||||||
pointer_width: 64,
|
pointer_width: 64,
|
||||||
data_layout: "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".to_string(),
|
data_layout: "e-m:e-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128".to_string(),
|
||||||
arch: "aarch64".to_string(),
|
arch: "aarch64".to_string(),
|
||||||
options: TargetOptions { mcount: "\u{1}_mcount".to_string(), ..base },
|
options: TargetOptions {
|
||||||
|
features: "+outline-atomics".to_string(),
|
||||||
|
mcount: "\u{1}_mcount".to_string(),
|
||||||
|
..base
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue