Skip to content

Commit 4e5b478

Browse files
committed
rewrite msvc-opt-minsize to rmake
1 parent c6bb357 commit 4e5b478

File tree

3 files changed

+19
-7
lines changed

3 files changed

+19
-7
lines changed

src/tools/tidy/src/allowed_run_make_makefiles.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,6 @@ run-make/mingw-export-call-convention/Makefile
107107
run-make/mismatching-target-triples/Makefile
108108
run-make/missing-crate-dependency/Makefile
109109
run-make/mixing-libs/Makefile
110-
run-make/msvc-opt-minsize/Makefile
111110
run-make/native-link-modifier-bundle/Makefile
112111
run-make/native-link-modifier-whole-archive/Makefile
113112
run-make/no-alloc-shim/Makefile

tests/run-make/msvc-opt-minsize/Makefile

Lines changed: 0 additions & 6 deletions
This file was deleted.
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
// A previously outdated version of LLVM caused compilation failures on Windows
2+
// specifically with optimization level `z`. After the update to a more recent LLVM
3+
// version, this test checks that compilation and execution both succeed.
4+
// See https://github.com/rust-lang/rust/issues/45034
5+
6+
// NOTE: This isn't an UI test despite its simplicity, because UI tests
7+
// cannot contain opt-level modifications.
8+
9+
//@ ignore-cross-compile
10+
// Reason: the compiled binary is executed
11+
//@ only-windows
12+
// Reason: the observed bug only occurs on Windows
13+
14+
use run_make_support::{run, rustc};
15+
16+
fn main() {
17+
rustc().input("foo.rs").opt_level("z").run();
18+
run("foo");
19+
}

0 commit comments

Comments
 (0)