Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

target tier policy compliance #116004

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
145 commits
Select commit Hold shift + click to select a range
5e548e1
doc: target tier policy with compiler-team#655
davidtwco Aug 25, 2023
cc28971
target compliance: x86_64h-apple-darwin
davidtwco Aug 29, 2023
16652f0
target compliance: *-wrs-vxworks
davidtwco Aug 29, 2023
ec2207a
target compliance: *-unknown-openbsd
davidtwco Aug 29, 2023
9ffe261
target compliance: *-unknown-linux-ohos
davidtwco Aug 29, 2023
61750e9
target compliance: x86_64-unknown-l4re-uclibc
davidtwco Aug 29, 2023
e9f3db4
target compliance: *-unknown-hermit
davidtwco Aug 29, 2023
eb644c8
target compliance: *-unknown-haiku
davidtwco Aug 29, 2023
6ad7f0f
target compliance: x86_64-unknown-dragonfly
davidtwco Aug 29, 2023
24016d2
target compliance: x86_64-unikraft-linux-musl
davidtwco Aug 29, 2023
2cb4531
target compliance: *-uwp-windows-{msvc,gnu}
davidtwco Aug 29, 2023
ceea4fa
target compliance: x86_64-sun-solaris
davidtwco Aug 29, 2023
1f8ce49
target compliance: drop windows xp in tier 3
davidtwco Aug 29, 2023
be2b697
target compliance: x86_64-pc-windows-gnullvm
davidtwco Aug 29, 2023
28109b5
target compliance: x86_64-pc-nto-qnx710
davidtwco Aug 29, 2023
85ce178
target compliance: *-apple-watchos{,-*}
davidtwco Aug 29, 2023
1947656
target compliance: *-apple-tvos
davidtwco Aug 29, 2023
5076fe7
target compliance: *-apple-ios-macabi
davidtwco Aug 29, 2023
44c6fdf
target compliance: wasm64-unknown-unknown
davidtwco Aug 29, 2023
92e5322
target compliance: wasm32-wasi-preview1-threads
davidtwco Aug 29, 2023
8169ca1
target compliance: thumbv7neon-unknown-linux-musleabihf
davidtwco Aug 29, 2023
23e54d0
target compliance: thumbv7a-pc-windows-msvc
davidtwco Aug 29, 2023
29b2ca8
target compliance: {arm,thumb}v5te-none-eabi
davidtwco Aug 29, 2023
4b49b81
target compliance: {arm,thumb}v4t-none-eabi
davidtwco Aug 29, 2023
e228da1
target compliance: sparc-unknown-none-elf
davidtwco Sep 8, 2023
f7f9e85
target compliance: sparc-unknown-linux-gnu
davidtwco Sep 8, 2023
9f7929c
target compliance: s390x-unknown-linux-musl
davidtwco Sep 8, 2023
13e23bb
target compliance: riscv64-linux-android
davidtwco Sep 8, 2023
1a49c26
target compliance: netbsd
davidtwco Sep 8, 2023
d034d66
target compliance: fuchsia
davidtwco Sep 8, 2023
d7a6a9e
target compliance: freebsd
davidtwco Sep 8, 2023
b987ec9
target compliance: *-esp-espidf
davidtwco Sep 8, 2023
4597e06
target compliance: riscv32imac-unknown-xous-elf
davidtwco Sep 8, 2023
792f37d
target compliance: riscv32im-unknown-none-elf
davidtwco Sep 8, 2023
521a962
target compliance: riscv{32,64}gc-unknown-linux-musl
davidtwco Sep 8, 2023
66a1f1b
target compliance: riscv32gc-unknown-linux-gnu
davidtwco Sep 8, 2023
df33447
target compliance: powerpc64-ibm-aix
davidtwco Sep 8, 2023
8c33187
target compliance: powerpc64{,le}-unknown-linux-musl
davidtwco Sep 8, 2023
12c5564
target compliance: powerpc-unknown-linux-musl
davidtwco Sep 8, 2023
28d31fc
target compliance: powerpc-unknown-linux-gnuspe
davidtwco Sep 8, 2023
28c6d09
target compliance: msp430-none-elf
davidtwco Sep 8, 2023
13bba49
target compliance: mipsisa{32r6,32r6el,64r6,64r6el}-unknown-linux-gnu…
davidtwco Sep 8, 2023
4067e5d
target compliance: mipsel-unknown-none
davidtwco Sep 8, 2023
a3e4a7e
target compliance: mipsel-unknown-linux-uclibc
davidtwco Sep 8, 2023
2325f91
target compliance: mipsel-sony-psx
davidtwco Sep 8, 2023
55f3416
target compliance: mipsel-sony-psp
davidtwco Sep 8, 2023
edf7a4b
target compliance: mips64-openwrt-linux-musl
davidtwco Sep 8, 2023
04d6c8b
target compliance: mips-unknown-linux-uclibc
davidtwco Sep 8, 2023
343ed33
target compliance: m68k-unknown-linux-gnu
davidtwco Sep 8, 2023
4354c65
target compliance: loongarch64-unknown-none{,-softfloat}
davidtwco Sep 8, 2023
ea63ade
target compliance: *-{pc,uwp}-windows-msvc
davidtwco Sep 11, 2023
2a223d3
target compliance: i686-apple-darwin
davidtwco Sep 11, 2023
2f962fb
target compliance: i586-pc-nto-qnx700
davidtwco Sep 11, 2023
83b931d
target compliance: i386-apple-ios
davidtwco Sep 11, 2023
006f459
target compliance: hexagon-unknown-linux-musl
davidtwco Sep 11, 2023
d9f5fc5
target compliance: csky-unknown-linux-gnuabiv2
davidtwco Sep 11, 2023
814ea89
target compliance: bpf
davidtwco Sep 11, 2023
677fd51
target compliance: avr
davidtwco Sep 11, 2023
27a3682
target compliance: armv7s-apple-ios
davidtwco Sep 11, 2023
1d5921c
target compliance: armv7a-none-eabihf
davidtwco Sep 11, 2023
3232d01
target compliance: {aarch64,armv7a}-kmc-solid_asp3{,-eabi,-eabihf}
davidtwco Sep 11, 2023
65c2bbf
target compliance: armv7-unknown-linux-uclibceabihf
davidtwco Sep 11, 2023
82bcc00
target compliance: armv7-unknown-linux-uclibceabi
davidtwco Sep 11, 2023
34cc90c
target compliance: armv7-apple-ios
davidtwco Sep 11, 2023
9017044
target compliance: armv6k-nintendo-3ds
davidtwco Sep 11, 2023
d7da694
target compliance: armv5te-unknown-linux-uclibceabi
davidtwco Sep 11, 2023
cf81738
target compliance: armv4t-unknown-linux-gnueabi
davidtwco Sep 11, 2023
023764c
target compliance: armeb-unknown-linux-gnueabi
davidtwco Sep 11, 2023
57473bb
target compliance: aarch64_be-unknown-linux-gnu{,_ilp32}
davidtwco Sep 11, 2023
a5fa026
target compliance: aarch64-unknown-redox
davidtwco Sep 11, 2023
f66038f
target compliance: aarch64-unknown-linux-gnu_ilp32
davidtwco Sep 11, 2023
439559b
target compliance: aarch64-unknown-nto-qnx710
davidtwco Sep 11, 2023
11d6408
target compliance: aarch64-unknown-teeos
davidtwco Sep 11, 2023
4e88447
target compliance: aarch64-pc-windows-gnullvm
davidtwco Sep 11, 2023
2fcadaa
target compliance: aarch64-nintendo-switch-freestanding
davidtwco Sep 11, 2023
818f335
target compliance: x86_64-unknown-uefi
davidtwco Sep 11, 2023
46f63bd
target compliance: x86_64-unknown-redox
davidtwco Sep 11, 2023
387d4fb
target compliance: x86_64-unknown-none
davidtwco Sep 11, 2023
074dec8
target compliance: x86_64-unknown-linux-gnux32
davidtwco Sep 11, 2023
61afec9
target compliance: x86_64-pc-solaris
davidtwco Sep 11, 2023
d800c85
target compliance: x86_64-linux-android
davidtwco Sep 11, 2023
cd171c6
target compliance: x86_64-fortanix-unknown-sgx
davidtwco Sep 11, 2023
1007b1e
target compliance: x86_64-apple-ios
davidtwco Sep 11, 2023
1398375
target compliance: wasm32-wasi
davidtwco Sep 11, 2023
a6fe718
target compliance: wasm32-unknown-unknown
davidtwco Sep 11, 2023
ff99f86
target compliance: wasm32-unknown-emscripten
davidtwco Sep 11, 2023
2dd9844
target compliance: thumbv8m.main-none-eabi{,hf}
davidtwco Sep 12, 2023
7d070ae
target compliance: thumbv8m.base-none-eabi
davidtwco Sep 12, 2023
7bc7e34
target compliance: thumbv7neon-unknown-linux-gnueabihf
davidtwco Sep 12, 2023
205d932
target compliance: thumbs
davidtwco Sep 12, 2023
3249a8b
target compliance: thumbv7neon-linux-androideabi
davidtwco Sep 12, 2023
7946d7f
target compliance: sparcv9-sun-solaris
davidtwco Sep 12, 2023
9765867
target compliance: sparc64-unknown-linux-gnu
davidtwco Sep 12, 2023
b72f273
target compliance: riscv64imac-unknown-none-elf
davidtwco Sep 12, 2023
7194cec
target compliance: riscv{32,64}{i,imc,imac,gc}-unknown-none-elf
davidtwco Sep 12, 2023
7e9c2b0
target compliance: nvptx64-nvidia-cuda
davidtwco Sep 12, 2023
5dbfdb2
target compliance: mips{el}-unknown-linux-musl
davidtwco Sep 12, 2023
bf1db71
target compliance: mips64{,el}-unknown-linux-muslabi64
davidtwco Sep 12, 2023
2be3c3d
target compliance: i686-unknown-uefi
davidtwco Sep 12, 2023
3ba756c
target compliance: i686-unknown-linux-musl
davidtwco Sep 12, 2023
260530c
target compliance: i686-linux-android
davidtwco Sep 12, 2023
2310d63
target compliance: i586-unknown-linux-{gnu,musl}
davidtwco Sep 12, 2023
7f0c721
target compliance: asmjs-unknown-emscripten
davidtwco Sep 12, 2023
eb4a728
target compliance: arm{,eb}v7r-none-eabi{,hf}
davidtwco Sep 12, 2023
275d932
target compliance: armv7a-none-eabi
davidtwco Sep 12, 2023
04244ac
target compliance: armv7-unknown-linux-*
davidtwco Sep 12, 2023
4c27eb6
target compliance: armv7-linux-androideabi
davidtwco Sep 12, 2023
7ed2d41
target compliance: armv5te-unknown-linux-musleabi
davidtwco Sep 12, 2023
2fded6c
target compliance: armv5te-unknown-linux-gnueabi
davidtwco Sep 12, 2023
b3fcd00
target compliance: arm-unknown-linux-musleabi{,hf}
davidtwco Sep 12, 2023
f13291f
target compliance: arm-linux-androideabi
davidtwco Sep 12, 2023
1480abb
target compliance: aarch64-unknown-uefi
davidtwco Sep 12, 2023
48b5b92
target compliance: aarch64-unknown-none{,-softfloat}
davidtwco Sep 12, 2023
53b6839
target compliance: aarch64-linux-android
davidtwco Sep 12, 2023
baaa94d
target compliance: aarch64-apple-ios-sim
davidtwco Sep 12, 2023
5c3257f
target compliance: aarch64-apple-ios
davidtwco Sep 12, 2023
3b31f46
target compliance: x86_64-unknown-linux-musl
davidtwco Sep 12, 2023
1d86a04
target compliance: x86_64-unknown-illumos
davidtwco Sep 12, 2023
2fef4a2
target compliance: s390x-unknown-linux-gnu
davidtwco Sep 12, 2023
0e5af92
target compliance: riscv64gc-unknown-linux-gnu
davidtwco Sep 12, 2023
18cb8af
target compliance: powerpc64{,le}-unknown-linux-gnu
davidtwco Sep 12, 2023
d44c9e1
target compliance: powerpc-unknown-linux-gnu
davidtwco Sep 12, 2023
cf06153
target compliance: misp{,el}-unknown-linux-gnu
davidtwco Sep 12, 2023
a78c838
target compliance: mips64{,el}-unknown-linux-gnuabi64
davidtwco Sep 12, 2023
e5e79ce
target compliance: loongarch64-unknown-linux-gnu
davidtwco Sep 12, 2023
71674ac
target compliance: armv7-unknown-linux-gnueabihf
davidtwco Sep 12, 2023
23fdc0c
target compliance: arm-unknown-linux-gnueabi{,hf}
davidtwco Sep 12, 2023
e6b1447
target compliance: aarch64-unknown-linux-musl
davidtwco Sep 12, 2023
654e5b5
target compliance: aarch64-apple-darwin
davidtwco Sep 20, 2023
0b5a849
target compliance: x86_64-unknown-linux-gnu
davidtwco Sep 12, 2023
91908f1
target compliance: x86_64-pc-windows-gnu
davidtwco Sep 12, 2023
b269571
target compliance: x86_64-apple-darwin
davidtwco Sep 12, 2023
f7cd648
target compliance: i686-unknown-linux-gnu
davidtwco Sep 12, 2023
25ac7a0
target compliance: i686-pc-windows-gnu
davidtwco Sep 12, 2023
668fc9d
target compliance: aarch64-unknown-linux-gnu
davidtwco Sep 12, 2023
93e572b
rustc_target: move base specs into a module
davidtwco Sep 12, 2023
f759acf
target compliance: i686-pc-windows-gnullvm
davidtwco Sep 12, 2023
b916d45
rustc_target: rename module to match target
davidtwco Sep 13, 2023
44b2082
doc/rustc: rename docs to match target defns
davidtwco Sep 13, 2023
4847641
tidy: add lint for target policy compliance
davidtwco Sep 13, 2023
674ccbb
doc/rustc: every target has its own page
davidtwco Sep 13, 2023
87fe421
target compliance: armv7-sony-vita-newlibeabihf
davidtwco Sep 13, 2023
94116c0
rustc_target: add missing i386/i486
davidtwco Sep 13, 2023
64a9b74
tidy: look for unused tests/docs in target policy
davidtwco Sep 13, 2023
6199d59
doc/rustc: add new platform support docs to SUMMARY
davidtwco Sep 20, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
6 changes: 4 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_apple_darwin.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use super::apple_base::{macos_llvm_target, opts, Arch};
use crate::spec::{FramePointer, SanitizerSet, Target, TargetOptions};
use crate::spec::{
base::apple::{macos_llvm_target, opts, Arch},
FramePointer, SanitizerSet, Target, TargetOptions,
};

Comment on lines +1 to +4
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Elsewhere in rustc we don't use nested use afaik.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we might in some places, though admittedly it is less common, but unless you've got a one-liner that I can change these all with, they can stay this way until we've got a formatter or something like that fixing it and enforcing a standard - I don't want to go through all those files again just for a minor formatting preference.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rustfmt has the unstable import_granularity config: https://rust-lang.github.io/rustfmt/?version=v1.6.0&search=import#imports_granularity Using the module value would work I think.

Try build/host/rustfmt/bin/rustfmt --config imports_granularity=module compiler/rustc_target/src/spec/**/*.rs.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would also prefer to keep imports as is, and do the super::apple_base -> super::base::apple transformation instead.
The PR is already too large without the import changes.

Copy link
Member

@RalfJung RalfJung Sep 21, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I use nested use a lot so in the parts of rustc I work on, they occur regularly.

However, no need to change the style on existing files.

pub fn target() -> Target {
let arch = Arch::Arm64;
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_apple_ios.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use super::apple_base::{ios_llvm_target, opts, Arch};
use crate::spec::{FramePointer, SanitizerSet, Target, TargetOptions};
use crate::spec::{
base::apple::{ios_llvm_target, opts, Arch},
FramePointer, SanitizerSet, Target, TargetOptions,
};

pub fn target() -> Target {
let arch = Arch::Arm64;
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_apple_ios_macabi.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use super::apple_base::{opts, Arch};
use crate::spec::{Cc, FramePointer, LinkerFlavor, Lld, SanitizerSet, Target, TargetOptions};
use crate::spec::{
base::apple::{opts, Arch},
Cc, FramePointer, LinkerFlavor, Lld, SanitizerSet, Target, TargetOptions,
};

pub fn target() -> Target {
let llvm_target = "arm64-apple-ios14.0-macabi";
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_apple_ios_sim.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use super::apple_base::{ios_sim_llvm_target, opts, Arch};
use crate::spec::{FramePointer, SanitizerSet, Target, TargetOptions};
use crate::spec::{
base::apple::{ios_sim_llvm_target, opts, Arch},
FramePointer, SanitizerSet, Target, TargetOptions,
};

pub fn target() -> Target {
let arch = Arch::Arm64_sim;
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_apple_tvos.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use super::apple_base::{opts, tvos_llvm_target, Arch};
use crate::spec::{FramePointer, Target, TargetOptions};
use crate::spec::{
base::apple::{opts, tvos_llvm_target, Arch},
FramePointer, Target, TargetOptions,
};

pub fn target() -> Target {
let arch = Arch::Arm64;
Expand Down
6 changes: 4 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_apple_watchos_sim.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use super::apple_base::{opts, watchos_sim_llvm_target, Arch};
use crate::spec::{FramePointer, Target, TargetOptions};
use crate::spec::{
base::apple::{opts, watchos_sim_llvm_target, Arch},
FramePointer, Target, TargetOptions,
};

pub fn target() -> Target {
let arch = Arch::Arm64_sim;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use crate::abi::Endian;
use crate::spec::{Target, TargetOptions};
use crate::{
abi::Endian,
spec::{base::linux_gnu, Target, TargetOptions},
};

pub fn target() -> Target {
Target {
Expand All @@ -12,7 +14,7 @@ pub fn target() -> Target {
max_atomic_width: Some(128),
mcount: "\u{1}_mcount".into(),
endian: Endian::Big,
..super::linux_gnu_base::opts()
..linux_gnu::opts()
},
}
}
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
use crate::abi::Endian;
use crate::spec::{Target, TargetOptions};
use crate::{
abi::Endian,
spec::{base::linux_gnu, Target, TargetOptions},
};

pub fn target() -> Target {
let mut base = super::linux_gnu_base::opts();
let mut base = linux_gnu::opts();
base.max_atomic_width = Some(128);

Target {
Expand Down
8 changes: 5 additions & 3 deletions compiler/rustc_target/src/spec/aarch64_be_unknown_netbsd.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use crate::abi::Endian;
use crate::spec::{Target, TargetOptions};
use crate::{
abi::Endian,
spec::{base::netbsd, Target, TargetOptions},
};

pub fn target() -> Target {
Target {
Expand All @@ -11,7 +13,7 @@ pub fn target() -> Target {
mcount: "__mcount".into(),
max_atomic_width: Some(128),
endian: Endian::Big,
..super::netbsd_base::opts()
..netbsd::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_kmc_solid_asp3.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use super::{RelocModel, Target, TargetOptions};
use crate::spec::{base::solid, RelocModel, Target, TargetOptions};

pub fn target() -> Target {
let base = super::solid_base::opts("asp3");
let base = solid::opts("asp3");
Target {
llvm_target: "aarch64-unknown-none".into(),
pointer_width: 64,
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_linux_android.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{SanitizerSet, Target, TargetOptions};
use crate::spec::{base::android, SanitizerSet, Target, TargetOptions};

// See https://developer.android.com/ndk/guides/abis.html#arm64-v8a
// for target ABI requirements.
Expand All @@ -20,7 +20,7 @@ pub fn target() -> Target {
| SanitizerSet::SHADOWCALLSTACK
| SanitizerSet::ADDRESS,
supports_xray: true,
..super::android_base::opts()
..android::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_pc_windows_gnullvm.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::spec::Target;
use crate::spec::{base::windows_gnullvm, Target};

pub fn target() -> Target {
let mut base = super::windows_gnullvm_base::opts();
let mut base = windows_gnullvm::opts();
base.max_atomic_width = Some(128);
base.features = "+v8a,+neon,+fp-armv8".into();
base.linker = Some("aarch64-w64-mingw32-clang".into());
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_pc_windows_msvc.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::spec::Target;
use crate::spec::{base::windows_msvc, Target};

pub fn target() -> Target {
let mut base = super::windows_msvc_base::opts();
let mut base = windows_msvc::opts();
base.max_atomic_width = Some(128);
base.features = "+v8a,+neon,+fp-armv8".into();

Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_freebsd.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{SanitizerSet, Target, TargetOptions};
use crate::spec::{base::freebsd, SanitizerSet, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -13,7 +13,7 @@ pub fn target() -> Target {
| SanitizerSet::CFI
| SanitizerSet::MEMORY
| SanitizerSet::THREAD,
..super::freebsd_base::opts()
..freebsd::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_fuchsia.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{SanitizerSet, Target, TargetOptions};
use crate::spec::{base::fuchsia, SanitizerSet, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -12,7 +12,7 @@ pub fn target() -> Target {
supported_sanitizers: SanitizerSet::ADDRESS
| SanitizerSet::CFI
| SanitizerSet::SHADOWCALLSTACK,
..super::fuchsia_base::opts()
..fuchsia::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_hermit.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{Target, TargetOptions};
use crate::spec::{base::hermit, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -9,7 +9,7 @@ pub fn target() -> Target {
options: TargetOptions {
features: "+v8a,+strict-align,+neon,+fp-armv8".into(),
max_atomic_width: Some(128),
..super::hermit_base::opts()
..hermit::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_linux_gnu.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{SanitizerSet, Target, TargetOptions};
use crate::spec::{base::linux_gnu, SanitizerSet, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -18,7 +18,7 @@ pub fn target() -> Target {
| SanitizerSet::THREAD
| SanitizerSet::HWADDRESS,
supports_xray: true,
..super::linux_gnu_base::opts()
..linux_gnu::opts()
},
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{Target, TargetOptions};
use crate::spec::{base::linux_gnu, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -11,7 +11,7 @@ pub fn target() -> Target {
features: "+v8a,+outline-atomics".into(),
max_atomic_width: Some(128),
mcount: "\u{1}_mcount".into(),
..super::linux_gnu_base::opts()
..linux_gnu::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_linux_musl.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::spec::{SanitizerSet, Target, TargetOptions};
use crate::spec::{base::linux_musl, SanitizerSet, Target, TargetOptions};

pub fn target() -> Target {
let mut base = super::linux_musl_base::opts();
let mut base = linux_musl::opts();
base.max_atomic_width = Some(128);
base.supports_xray = true;
base.features = "+v8a".into();
Expand Down
6 changes: 2 additions & 4 deletions compiler/rustc_target/src/spec/aarch64_unknown_linux_ohos.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
use crate::spec::{Target, TargetOptions};

use super::SanitizerSet;
use crate::spec::{base::linux_ohos, SanitizerSet, Target, TargetOptions};

pub fn target() -> Target {
let mut base = super::linux_ohos_base::opts();
let mut base = linux_ohos::opts();
base.max_atomic_width = Some(128);

Target {
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_netbsd.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{Target, TargetOptions};
use crate::spec::{base::netbsd, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -10,7 +10,7 @@ pub fn target() -> Target {
features: "+v8a".into(),
mcount: "__mcount".into(),
max_atomic_width: Some(128),
..super::netbsd_base::opts()
..netbsd::opts()
},
}
}
2 changes: 1 addition & 1 deletion compiler/rustc_target/src/spec/aarch64_unknown_none.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//
// For example, `-C target-cpu=cortex-a53`.

use super::{
use crate::spec::{
Cc, LinkerFlavor, Lld, PanicStrategy, RelocModel, SanitizerSet, Target, TargetOptions,
};

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use super::nto_qnx_base;
use crate::spec::{Cc, LinkerFlavor, Lld, Target, TargetOptions};
use crate::spec::{base::nto_qnx, Cc, LinkerFlavor, Lld, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -24,7 +23,7 @@ pub fn target() -> Target {
&["-Vgcc_ntoaarch64le_cxx"],
),
env: "nto71".into(),
..nto_qnx_base::opts()
..nto_qnx::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_openbsd.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{Target, TargetOptions};
use crate::spec::{base::openbsd, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -9,7 +9,7 @@ pub fn target() -> Target {
options: TargetOptions {
features: "+v8a".into(),
max_atomic_width: Some(128),
..super::openbsd_base::opts()
..openbsd::opts()
},
}
}
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_redox.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::spec::Target;
use crate::spec::{base::redox, Target};

pub fn target() -> Target {
let mut base = super::redox_base::opts();
let mut base = redox::opts();
base.max_atomic_width = Some(128);
base.features = "+v8a".into();

Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_unknown_teeos.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::spec::Target;
use crate::spec::{base::teeos, Target};

pub fn target() -> Target {
let mut base = super::teeos_base::opts();
let mut base = teeos::opts();
base.features = "+strict-align,+neon,+fp-armv8".into();
base.max_atomic_width = Some(128);
base.linker = Some("aarch64-linux-gnu-ld".into());
Expand Down
5 changes: 2 additions & 3 deletions compiler/rustc_target/src/spec/aarch64_unknown_uefi.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
// This defines the aarch64 target for UEFI systems as described in the UEFI specification. See the
// uefi-base module for generic UEFI options.

use super::uefi_msvc_base;
use crate::spec::{LinkerFlavor, Lld, Target};
use crate::spec::{base::uefi_msvc, LinkerFlavor, Lld, Target};

pub fn target() -> Target {
let mut base = uefi_msvc_base::opts();
let mut base = uefi_msvc::opts();

base.max_atomic_width = Some(128);
base.add_pre_link_args(LinkerFlavor::Msvc(Lld::No), &["/machine:arm64"]);
Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_uwp_windows_msvc.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::spec::Target;
use crate::spec::{base::windows_uwp_msvc, Target};

pub fn target() -> Target {
let mut base = super::windows_uwp_msvc_base::opts();
let mut base = windows_uwp_msvc::opts();
base.max_atomic_width = Some(128);
base.features = "+v8a".into();

Expand Down
4 changes: 2 additions & 2 deletions compiler/rustc_target/src/spec/aarch64_wrs_vxworks.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use crate::spec::{Target, TargetOptions};
use crate::spec::{base::vxworks, Target, TargetOptions};

pub fn target() -> Target {
Target {
Expand All @@ -9,7 +9,7 @@ pub fn target() -> Target {
options: TargetOptions {
features: "+v8a".into(),
max_atomic_width: Some(128),
..super::vxworks_base::opts()
..vxworks::opts()
},
}
}
7 changes: 4 additions & 3 deletions compiler/rustc_target/src/spec/abi.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ use rustc_macros::HashStable_Generic;
use rustc_span::symbol::sym;
use rustc_span::{Span, Symbol};

#[cfg(test)]
mod tests;

#[derive(PartialEq, Eq, PartialOrd, Ord, Hash, Clone, Copy, Debug)]
#[derive(HashStable_Generic, Encodable, Decodable)]
pub enum Abi {
Expand Down Expand Up @@ -339,3 +336,7 @@ impl fmt::Display for Abi {
write!(f, "\"{}\"", self.name())
}
}

#[cfg(test)]
#[path = "tests/abi_tests.rs"]
mod tests_api;
6 changes: 4 additions & 2 deletions compiler/rustc_target/src/spec/arm64_32_apple_watchos.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
use super::apple_base::{opts, Arch};
use crate::spec::{Target, TargetOptions};
use crate::spec::{
base::apple::{opts, Arch},
Target, TargetOptions,
};

pub fn target() -> Target {
let base = opts("watchos", Arch::Arm64_32);
Expand Down
Loading
Loading