Skip to content

Commit 29e15ef

Browse files
Rollup merge of rust-lang#137957 - Noratrieb:no, r=wesleywiser
Remove i586-pc-windows-msvc See [MCP 840](rust-lang/compiler-team#840). I left a specialized error message that should help users that hit this in the wild (for example, because they use it in their CI). ``` error: Error loading target specification: the `i586-pc-windows-msvc` target has been removed. Use the `i686-pc-windows-msvc` target instead. Windows 10 (the minimum required OS version) requires a CPU baseline of at least i686 so you can safely switch. Run `rustc --print target-list` for a list of built-in targets ``` `@workingjubilee` `@calebzulawski` fyi portable-simd uses this target in CI, if you wanna remove it already before this happens
2 parents b341cae + b5562c0 commit 29e15ef

File tree

7 files changed

+11
-22
lines changed

7 files changed

+11
-22
lines changed

compiler/rustc_target/src/spec/mod.rs

+9-2
Original file line numberDiff line numberDiff line change
@@ -1915,7 +1915,6 @@ supported_targets! {
19151915
("i686-pc-windows-msvc", i686_pc_windows_msvc),
19161916
("i686-uwp-windows-msvc", i686_uwp_windows_msvc),
19171917
("i686-win7-windows-msvc", i686_win7_windows_msvc),
1918-
("i586-pc-windows-msvc", i586_pc_windows_msvc),
19191918
("thumbv7a-pc-windows-msvc", thumbv7a_pc_windows_msvc),
19201919
("thumbv7a-uwp-windows-msvc", thumbv7a_uwp_windows_msvc),
19211920

@@ -3504,7 +3503,15 @@ impl Target {
35043503
return load_file(&p);
35053504
}
35063505

3507-
Err(format!("Could not find specification for target {target_tuple:?}"))
3506+
// Leave in a specialized error message for the removed target.
3507+
// FIXME: If you see this and it's been a few months after this has been released,
3508+
// you can probably remove it.
3509+
if target_tuple == "i586-pc-windows-msvc" {
3510+
Err("the `i586-pc-windows-msvc` target has been removed. Use the `i686-pc-windows-msvc` target instead.\n\
3511+
Windows 10 (the minimum required OS version) requires a CPU baseline of at least i686 so you can safely switch".into())
3512+
} else {
3513+
Err(format!("Could not find specification for target {target_tuple:?}"))
3514+
}
35083515
}
35093516
TargetTuple::TargetJson { ref contents, .. } => {
35103517
let obj = serde_json::from_str(contents).map_err(|e| e.to_string())?;

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

-9
This file was deleted.

src/ci/github-actions/jobs.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -591,7 +591,7 @@ auto:
591591
RUST_CONFIGURE_ARGS: >-
592592
--build=i686-pc-windows-msvc
593593
--host=i686-pc-windows-msvc
594-
--target=i686-pc-windows-msvc,i586-pc-windows-msvc
594+
--target=i686-pc-windows-msvc
595595
--enable-full-tools
596596
--enable-profiler
597597
SCRIPT: python x.py dist bootstrap --include-default-paths

src/doc/rustc/src/platform-support.md

-1
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,6 @@ target | std | notes
162162
[`armv7a-none-eabi`](platform-support/arm-none-eabi.md) | * | Bare Armv7-A
163163
[`armv7r-none-eabi`](platform-support/armv7r-none-eabi.md) | * | Bare Armv7-R
164164
[`armv7r-none-eabihf`](platform-support/armv7r-none-eabi.md) | * | Bare Armv7-R, hardfloat
165-
`i586-pc-windows-msvc` | * | 32-bit Windows (original Pentium) [^x86_32-floats-x87]
166165
`i586-unknown-linux-gnu` | ✓ | 32-bit Linux (kernel 3.2, glibc 2.17, original Pentium) [^x86_32-floats-x87]
167166
`i586-unknown-linux-musl` | ✓ | 32-bit Linux (musl 1.2.3, original Pentium) [^x86_32-floats-x87]
168167
[`i686-linux-android`](platform-support/android.md) | ✓ | 32-bit x86 Android ([Pentium 4 plus various extensions](https://developer.android.com/ndk/guides/abis.html#x86)) [^x86_32-floats-return-ABI]

src/tools/build-manifest/src/main.rs

-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,6 @@ static TARGETS: &[&str] = &[
9797
"bpfeb-unknown-none",
9898
"bpfel-unknown-none",
9999
"i386-apple-ios",
100-
"i586-pc-windows-msvc",
101100
"i586-unknown-linux-gnu",
102101
"i586-unknown-linux-musl",
103102
"i586-unknown-redox",

tests/assembly/stack-protector/stack-protector-target-support.rs

+1-5
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
//
44
//@ add-core-stubs
55
//@ revisions: r1 r2 r3 r4 r5 r6 r7 r8 r9 r10 r11 r12 r13 r14 r15 r16 r17 r18 r19 r20 r21 r22 r23
6-
//@ revisions: r24 r25 r26 r27 r28 r29 r30 r31 r32 r33 r35 r36 r37 r38 r39 r40 r41 r42 r43 r44
6+
//@ revisions: r24 r25 r26 r27 r28 r29 r30 r31 r32 r33 r36 r37 r38 r39 r40 r41 r42 r43 r44
77
//@ revisions: r45 r46 r47 r48 r49 r50 r51 r52 r53 r54 r55 r56 r57 r58 r59 r60 r61 r62 r63 r64 r65
88
//@ revisions: r66 r67 r68 r69 r70 r71 r72 r73 r74 r75 r76 r77 r78 r79 r80 r81 r82 r83 r84 r85
99
//@ assembly-output: emit-asm
@@ -73,9 +73,6 @@
7373
//@ [r32] needs-llvm-components: arm
7474
//@ [r33] compile-flags: --target armv7-unknown-linux-musleabihf
7575
//@ [r33] needs-llvm-components: arm
76-
77-
//@ [r35] compile-flags: --target i586-pc-windows-msvc
78-
//@ [r35] needs-llvm-components: x86
7976
//@ [r36] compile-flags: --target i586-unknown-linux-gnu
8077
//@ [r36] needs-llvm-components: x86
8178
//@ [r37] compile-flags: --target i586-unknown-linux-musl
@@ -195,7 +192,6 @@ pub fn foo() {
195192
// r3: calll @__security_check_cookie
196193
// r7: callq __security_check_cookie
197194
// r13: bl __security_check_cookie
198-
// r35: calll @__security_check_cookie
199195

200196
// cuda doesn't support stack-smash protection
201197
// r49-NOT: __security_check_cookie

tests/assembly/targets/targets-pe.rs

-3
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,6 @@
2525
//@ revisions: bpfel_unknown_none
2626
//@ [bpfel_unknown_none] compile-flags: --target bpfel-unknown-none
2727
//@ [bpfel_unknown_none] needs-llvm-components: bpf
28-
//@ revisions: i586_pc_windows_msvc
29-
//@ [i586_pc_windows_msvc] compile-flags: --target i586-pc-windows-msvc
30-
//@ [i586_pc_windows_msvc] needs-llvm-components: x86
3128
//@ revisions: i686_pc_windows_gnu
3229
//@ [i686_pc_windows_gnu] compile-flags: --target i686-pc-windows-gnu
3330
//@ [i686_pc_windows_gnu] needs-llvm-components: x86

0 commit comments

Comments
 (0)