Skip to content

Commit 76aa83e

Browse files
committed
target: move base specs to spec/base
Signed-off-by: David Wood <david@davidtw.co>
1 parent 0d5ec96 commit 76aa83e

File tree

229 files changed

+453
-449
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

229 files changed

+453
-449
lines changed

compiler/rustc_target/src/spec/aarch64_apple_darwin.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{macos_llvm_target, opts, Arch};
1+
use crate::spec::base::apple::{macos_llvm_target, opts, Arch};
22
use crate::spec::{FramePointer, SanitizerSet, Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/aarch64_apple_ios.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{ios_llvm_target, opts, Arch};
1+
use crate::spec::base::apple::{ios_llvm_target, opts, Arch};
22
use crate::spec::{FramePointer, SanitizerSet, Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/aarch64_apple_ios_macabi.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{opts, Arch};
1+
use crate::spec::base::apple::{opts, Arch};
22
use crate::spec::{Cc, FramePointer, LinkerFlavor, Lld, SanitizerSet, Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/aarch64_apple_ios_sim.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{ios_sim_llvm_target, opts, Arch};
1+
use crate::spec::base::apple::{ios_sim_llvm_target, opts, Arch};
22
use crate::spec::{FramePointer, SanitizerSet, Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/aarch64_apple_tvos.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{opts, tvos_llvm_target, Arch};
1+
use crate::spec::base::apple::{opts, tvos_llvm_target, Arch};
22
use crate::spec::{FramePointer, Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/aarch64_apple_tvos_sim.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{opts, tvos_sim_llvm_target, Arch};
1+
use crate::spec::base::apple::{opts, tvos_sim_llvm_target, Arch};
22
use crate::spec::{FramePointer, Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/aarch64_apple_watchos_sim.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{opts, watchos_sim_llvm_target, Arch};
1+
use crate::spec::base::apple::{opts, watchos_sim_llvm_target, Arch};
22
use crate::spec::{FramePointer, Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/aarch64_be_unknown_linux_gnu.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use crate::abi::Endian;
2-
use crate::spec::{Target, TargetOptions};
2+
use crate::spec::{base, Target, TargetOptions};
33

44
pub fn target() -> Target {
55
Target {
@@ -12,7 +12,7 @@ pub fn target() -> Target {
1212
max_atomic_width: Some(128),
1313
mcount: "\u{1}_mcount".into(),
1414
endian: Endian::Big,
15-
..super::linux_gnu_base::opts()
15+
..base::linux_gnu::opts()
1616
},
1717
}
1818
}

compiler/rustc_target/src/spec/aarch64_be_unknown_linux_gnu_ilp32.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
use crate::abi::Endian;
2-
use crate::spec::{Target, TargetOptions};
2+
use crate::spec::{base, Target, TargetOptions};
33

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

88
Target {

compiler/rustc_target/src/spec/aarch64_be_unknown_netbsd.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use crate::abi::Endian;
2-
use crate::spec::{Target, TargetOptions};
2+
use crate::spec::{base, Target, TargetOptions};
33

44
pub fn target() -> Target {
55
Target {
@@ -11,7 +11,7 @@ pub fn target() -> Target {
1111
mcount: "__mcount".into(),
1212
max_atomic_width: Some(128),
1313
endian: Endian::Big,
14-
..super::netbsd_base::opts()
14+
..base::netbsd::opts()
1515
},
1616
}
1717
}

compiler/rustc_target/src/spec/aarch64_kmc_solid_asp3.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use super::{RelocModel, Target, TargetOptions};
1+
use super::{base, RelocModel, Target, TargetOptions};
22

33
pub fn target() -> Target {
4-
let base = super::solid_base::opts("asp3");
4+
let base = base::solid::opts("asp3");
55
Target {
66
llvm_target: "aarch64-unknown-none".into(),
77
pointer_width: 64,

compiler/rustc_target/src/spec/aarch64_linux_android.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{SanitizerSet, Target, TargetOptions};
1+
use crate::spec::{base, SanitizerSet, Target, TargetOptions};
22

33
// See https://developer.android.com/ndk/guides/abis.html#arm64-v8a
44
// for target ABI requirements.
@@ -20,7 +20,7 @@ pub fn target() -> Target {
2020
| SanitizerSet::SHADOWCALLSTACK
2121
| SanitizerSet::ADDRESS,
2222
supports_xray: true,
23-
..super::android_base::opts()
23+
..base::android::opts()
2424
},
2525
}
2626
}

compiler/rustc_target/src/spec/aarch64_pc_windows_gnullvm.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use crate::spec::Target;
1+
use crate::spec::{base, Target};
22

33
pub fn target() -> Target {
4-
let mut base = super::windows_gnullvm_base::opts();
4+
let mut base = base::windows_gnullvm::opts();
55
base.max_atomic_width = Some(128);
66
base.features = "+v8a,+neon,+fp-armv8".into();
77
base.linker = Some("aarch64-w64-mingw32-clang".into());

compiler/rustc_target/src/spec/aarch64_pc_windows_msvc.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use crate::spec::Target;
1+
use crate::spec::{base, Target};
22

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

compiler/rustc_target/src/spec/aarch64_unknown_freebsd.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{SanitizerSet, Target, TargetOptions};
1+
use crate::spec::{base, SanitizerSet, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -13,7 +13,7 @@ pub fn target() -> Target {
1313
| SanitizerSet::CFI
1414
| SanitizerSet::MEMORY
1515
| SanitizerSet::THREAD,
16-
..super::freebsd_base::opts()
16+
..base::freebsd::opts()
1717
},
1818
}
1919
}

compiler/rustc_target/src/spec/aarch64_unknown_fuchsia.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{SanitizerSet, Target, TargetOptions};
1+
use crate::spec::{base, SanitizerSet, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -12,7 +12,7 @@ pub fn target() -> Target {
1212
supported_sanitizers: SanitizerSet::ADDRESS
1313
| SanitizerSet::CFI
1414
| SanitizerSet::SHADOWCALLSTACK,
15-
..super::fuchsia_base::opts()
15+
..base::fuchsia::opts()
1616
},
1717
}
1818
}

compiler/rustc_target/src/spec/aarch64_unknown_hermit.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -9,7 +9,7 @@ pub fn target() -> Target {
99
options: TargetOptions {
1010
features: "+v8a,+strict-align,+neon,+fp-armv8".into(),
1111
max_atomic_width: Some(128),
12-
..super::hermit_base::opts()
12+
..base::hermit::opts()
1313
},
1414
}
1515
}

compiler/rustc_target/src/spec/aarch64_unknown_linux_gnu.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{SanitizerSet, Target, TargetOptions};
1+
use crate::spec::{base, SanitizerSet, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -18,7 +18,7 @@ pub fn target() -> Target {
1818
| SanitizerSet::THREAD
1919
| SanitizerSet::HWADDRESS,
2020
supports_xray: true,
21-
..super::linux_gnu_base::opts()
21+
..base::linux_gnu::opts()
2222
},
2323
}
2424
}

compiler/rustc_target/src/spec/aarch64_unknown_linux_gnu_ilp32.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -11,7 +11,7 @@ pub fn target() -> Target {
1111
features: "+v8a,+outline-atomics".into(),
1212
max_atomic_width: Some(128),
1313
mcount: "\u{1}_mcount".into(),
14-
..super::linux_gnu_base::opts()
14+
..base::linux_gnu::opts()
1515
},
1616
}
1717
}

compiler/rustc_target/src/spec/aarch64_unknown_linux_musl.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use crate::spec::{SanitizerSet, Target, TargetOptions};
1+
use crate::spec::{base, SanitizerSet, Target, TargetOptions};
22

33
pub fn target() -> Target {
4-
let mut base = super::linux_musl_base::opts();
4+
let mut base = base::linux_musl::opts();
55
base.max_atomic_width = Some(128);
66
base.supports_xray = true;
77
base.features = "+v8a".into();

compiler/rustc_target/src/spec/aarch64_unknown_linux_ohos.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
use super::SanitizerSet;
44

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

99
Target {

compiler/rustc_target/src/spec/aarch64_unknown_netbsd.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -10,7 +10,7 @@ pub fn target() -> Target {
1010
features: "+v8a".into(),
1111
mcount: "__mcount".into(),
1212
max_atomic_width: Some(128),
13-
..super::netbsd_base::opts()
13+
..base::netbsd::opts()
1414
},
1515
}
1616
}

compiler/rustc_target/src/spec/aarch64_unknown_nto_qnx_710.rs

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
use super::nto_qnx_base;
2-
use crate::spec::{Cc, LinkerFlavor, Lld, Target, TargetOptions};
1+
use crate::spec::{base, Cc, LinkerFlavor, Lld, Target, TargetOptions};
32

43
pub fn target() -> Target {
54
Target {
@@ -24,7 +23,7 @@ pub fn target() -> Target {
2423
&["-Vgcc_ntoaarch64le_cxx"],
2524
),
2625
env: "nto71".into(),
27-
..nto_qnx_base::opts()
26+
..base::nto_qnx::opts()
2827
},
2928
}
3029
}

compiler/rustc_target/src/spec/aarch64_unknown_openbsd.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -9,7 +9,7 @@ pub fn target() -> Target {
99
options: TargetOptions {
1010
features: "+v8a".into(),
1111
max_atomic_width: Some(128),
12-
..super::openbsd_base::opts()
12+
..base::openbsd::opts()
1313
},
1414
}
1515
}

compiler/rustc_target/src/spec/aarch64_unknown_redox.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use crate::spec::Target;
1+
use crate::spec::{base, Target};
22

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

compiler/rustc_target/src/spec/aarch64_unknown_teeos.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use crate::spec::Target;
1+
use crate::spec::{base, Target};
22

33
pub fn target() -> Target {
4-
let mut base = super::teeos_base::opts();
4+
let mut base = base::teeos::opts();
55
base.features = "+strict-align,+neon,+fp-armv8".into();
66
base.max_atomic_width = Some(128);
77
base.linker = Some("aarch64-linux-gnu-ld".into());

compiler/rustc_target/src/spec/aarch64_unknown_uefi.rs

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
// This defines the aarch64 target for UEFI systems as described in the UEFI specification. See the
22
// uefi-base module for generic UEFI options.
33

4-
use super::uefi_msvc_base;
5-
use crate::spec::{LinkerFlavor, Lld, Target};
4+
use crate::spec::{base, LinkerFlavor, Lld, Target};
65

76
pub fn target() -> Target {
8-
let mut base = uefi_msvc_base::opts();
7+
let mut base = base::uefi_msvc::opts();
98

109
base.max_atomic_width = Some(128);
1110
base.add_pre_link_args(LinkerFlavor::Msvc(Lld::No), &["/machine:arm64"]);

compiler/rustc_target/src/spec/aarch64_uwp_windows_msvc.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
use crate::spec::Target;
1+
use crate::spec::{base, Target};
22

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

compiler/rustc_target/src/spec/aarch64_wrs_vxworks.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -9,7 +9,7 @@ pub fn target() -> Target {
99
options: TargetOptions {
1010
features: "+v8a".into(),
1111
max_atomic_width: Some(128),
12-
..super::vxworks_base::opts()
12+
..base::vxworks::opts()
1313
},
1414
}
1515
}

compiler/rustc_target/src/spec/arm64_32_apple_watchos.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use super::apple_base::{opts, Arch};
1+
use crate::spec::base::apple::{opts, Arch};
22
use crate::spec::{Target, TargetOptions};
33

44
pub fn target() -> Target {

compiler/rustc_target/src/spec/arm_linux_androideabi.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{SanitizerSet, Target, TargetOptions};
1+
use crate::spec::{base, SanitizerSet, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -12,7 +12,7 @@ pub fn target() -> Target {
1212
features: "+strict-align,+v5te".into(),
1313
supported_sanitizers: SanitizerSet::ADDRESS,
1414
max_atomic_width: Some(32),
15-
..super::android_base::opts()
15+
..base::android::opts()
1616
},
1717
}
1818
}

compiler/rustc_target/src/spec/arm_unknown_linux_gnueabi.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -12,7 +12,7 @@ pub fn target() -> Target {
1212
max_atomic_width: Some(64),
1313
mcount: "\u{1}__gnu_mcount_nc".into(),
1414
llvm_mcount_intrinsic: Some("llvm.arm.gnu.eabi.mcount".into()),
15-
..super::linux_gnu_base::opts()
15+
..base::linux_gnu::opts()
1616
},
1717
}
1818
}

compiler/rustc_target/src/spec/arm_unknown_linux_gnueabihf.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -12,7 +12,7 @@ pub fn target() -> Target {
1212
max_atomic_width: Some(64),
1313
mcount: "\u{1}__gnu_mcount_nc".into(),
1414
llvm_mcount_intrinsic: Some("llvm.arm.gnu.eabi.mcount".into()),
15-
..super::linux_gnu_base::opts()
15+
..base::linux_gnu::opts()
1616
},
1717
}
1818
}

compiler/rustc_target/src/spec/arm_unknown_linux_musleabi.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
use crate::spec::{Target, TargetOptions};
1+
use crate::spec::{base, Target, TargetOptions};
22

33
pub fn target() -> Target {
44
Target {
@@ -16,7 +16,7 @@ pub fn target() -> Target {
1616
features: "+strict-align,+v6".into(),
1717
max_atomic_width: Some(64),
1818
mcount: "\u{1}mcount".into(),
19-
..super::linux_musl_base::opts()
19+
..base::linux_musl::opts()
2020
},
2121
}
2222
}

0 commit comments

Comments
 (0)