Skip to content

Commit 6cf6ca2

Browse files
Auto merge of #147896 - Zalathar:target, r=<try>
(EXPERIMENT) compiletest: Don't set `TARGET` for non-run-make tests try-job: dist-i586-gnu-i586-i686-musl
2 parents c0c37ca + bbd642f commit 6cf6ca2

File tree

3 files changed

+0
-24
lines changed

3 files changed

+0
-24
lines changed

src/tools/compiletest/src/lib.rs

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -525,11 +525,6 @@ fn run_tests(config: Arc<Config>) {
525525
// SAFETY: at this point we're still single-threaded.
526526
unsafe { env::set_var("__COMPAT_LAYER", "RunAsInvoker") };
527527

528-
// Let tests know which target they're running as.
529-
//
530-
// SAFETY: at this point we're still single-threaded.
531-
unsafe { env::set_var("TARGET", &config.target) };
532-
533528
let mut configs = Vec::new();
534529
if let TestMode::DebugInfo = config.mode {
535530
// Debugging emscripten code doesn't make sense today

tests/ui/abi/homogenous-floats-target-feature-mixup.rs

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,16 +19,6 @@ fn main() {
1919
return test::main(&level)
2020
}
2121

22-
match std::env::var("TARGET") {
23-
Ok(s) => {
24-
// Skip this tests on i586-unknown-linux-gnu where sse2 is disabled
25-
if s.contains("i586") {
26-
return
27-
}
28-
}
29-
Err(_) => return,
30-
}
31-
3222
let me = env::current_exe().unwrap();
3323
for level in ["sse", "avx", "avx512"].iter() {
3424
let status = Command::new(&me).arg(level).status().unwrap();

tests/ui/target-feature/target-feature-detection.rs

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,6 @@
99
use std::env;
1010

1111
fn main() {
12-
match env::var("TARGET") {
13-
Ok(s) => {
14-
// Skip this tests on i586-unknown-linux-gnu where sse2 is disabled
15-
if s.contains("i586") {
16-
return;
17-
}
18-
}
19-
Err(_) => return,
20-
}
2112
if cfg!(any(target_arch = "x86", target_arch = "x86_64")) {
2213
assert!(
2314
cfg!(target_feature = "sse2"),

0 commit comments

Comments
 (0)