Skip to content

Commit 7859a37

Browse files
committed
explicitly set llvm_abiname option on existing ppc64 targets
1 parent 3bc767e commit 7859a37

9 files changed

+9
-1
lines changed

compiler/rustc_target/src/spec/targets/powerpc64_unknown_freebsd.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ pub(crate) fn target() -> Target {
1010
base.add_pre_link_args(LinkerFlavor::Gnu(Cc::Yes, Lld::No), &["-m64"]);
1111
base.max_atomic_width = Some(64);
1212
base.stack_probes = StackProbeType::Inline;
13+
base.llvm_abiname = "elfv2".into();
1314

1415
Target {
1516
llvm_target: "powerpc64-unknown-freebsd".into(),

compiler/rustc_target/src/spec/targets/powerpc64_unknown_linux_gnu.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ pub(crate) fn target() -> Target {
1010
base.add_pre_link_args(LinkerFlavor::Gnu(Cc::Yes, Lld::No), &["-m64"]);
1111
base.max_atomic_width = Some(64);
1212
base.stack_probes = StackProbeType::Inline;
13+
base.llvm_abiname = "elfv1".into();
1314

1415
Target {
1516
llvm_target: "powerpc64-unknown-linux-gnu".into(),

compiler/rustc_target/src/spec/targets/powerpc64_unknown_linux_musl.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ pub(crate) fn target() -> Target {
1212
base.stack_probes = StackProbeType::Inline;
1313
// FIXME(compiler-team#422): musl targets should be dynamically linked by default.
1414
base.crt_static_default = true;
15+
base.llvm_abiname = "elfv2".into();
1516

1617
Target {
1718
llvm_target: "powerpc64-unknown-linux-musl".into(),

compiler/rustc_target/src/spec/targets/powerpc64_unknown_openbsd.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ pub(crate) fn target() -> Target {
1010
base.add_pre_link_args(LinkerFlavor::Gnu(Cc::Yes, Lld::No), &["-m64"]);
1111
base.max_atomic_width = Some(64);
1212
base.stack_probes = StackProbeType::Inline;
13+
base.llvm_abiname = "elfv2".into();
1314

1415
Target {
1516
llvm_target: "powerpc64-unknown-openbsd".into(),

compiler/rustc_target/src/spec/targets/powerpc64_wrs_vxworks.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ pub(crate) fn target() -> Target {
1010
base.add_pre_link_args(LinkerFlavor::Gnu(Cc::Yes, Lld::No), &["-m64"]);
1111
base.max_atomic_width = Some(64);
1212
base.stack_probes = StackProbeType::Inline;
13+
base.llvm_abiname = "elfv1".into();
1314

1415
Target {
1516
llvm_target: "powerpc64-unknown-linux-gnu".into(),

compiler/rustc_target/src/spec/targets/powerpc64le_unknown_freebsd.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ pub(crate) fn target() -> Target {
88
base.add_pre_link_args(LinkerFlavor::Gnu(Cc::Yes, Lld::No), &["-m64"]);
99
base.max_atomic_width = Some(64);
1010
base.stack_probes = StackProbeType::Inline;
11+
base.llvm_abiname = "elfv2".into();
1112

1213
Target {
1314
llvm_target: "powerpc64le-unknown-freebsd".into(),

compiler/rustc_target/src/spec/targets/powerpc64le_unknown_linux_gnu.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ pub(crate) fn target() -> Target {
88
base.add_pre_link_args(LinkerFlavor::Gnu(Cc::Yes, Lld::No), &["-m64"]);
99
base.max_atomic_width = Some(64);
1010
base.stack_probes = StackProbeType::Inline;
11+
base.llvm_abiname = "elfv2".into();
1112

1213
Target {
1314
llvm_target: "powerpc64le-unknown-linux-gnu".into(),

compiler/rustc_target/src/spec/targets/powerpc64le_unknown_linux_musl.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ pub(crate) fn target() -> Target {
1010
base.stack_probes = StackProbeType::Inline;
1111
// FIXME(compiler-team#422): musl targets should be dynamically linked by default.
1212
base.crt_static_default = true;
13+
base.llvm_abiname = "elfv2".into();
1314

1415
Target {
1516
llvm_target: "powerpc64le-unknown-linux-musl".into(),

tests/ui/check-cfg/well-known-values.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ warning: unexpected `cfg` condition value: `_UNEXPECTED_VALUE`
129129
LL | target_abi = "_UNEXPECTED_VALUE",
130130
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
131131
|
132-
= note: expected values for `target_abi` are: ``, `abi64`, `abiv2`, `abiv2hf`, `eabi`, `eabihf`, `fortanix`, `ilp32`, `ilp32e`, `llvm`, `macabi`, `sim`, `softfloat`, `spe`, `uwp`, `vec-extabi`, and `x32`
132+
= note: expected values for `target_abi` are: ``, `abi64`, `abiv2`, `abiv2hf`, `eabi`, `eabihf`, `elfv1`, `elfv2`, `fortanix`, `ilp32`, `ilp32e`, `llvm`, `macabi`, `sim`, `softfloat`, `spe`, `uwp`, `vec-extabi`, and `x32`
133133
= note: see <https://doc.rust-lang.org/nightly/rustc/check-cfg.html> for more information about checking conditional configuration
134134

135135
warning: unexpected `cfg` condition value: `_UNEXPECTED_VALUE`

0 commit comments

Comments
 (0)