Skip to content

Commit fbc869b

Browse files
committed
rewrite lto-linkage-used-attr to rmake
1 parent 0cd01aa commit fbc869b

File tree

3 files changed

+14
-9
lines changed

3 files changed

+14
-9
lines changed

src/tools/tidy/src/allowed_run_make_makefiles.txt

-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ run-make/link-framework/Makefile
5656
run-make/linkage-attr-on-static/Makefile
5757
run-make/long-linker-command-lines-cmd-exe/Makefile
5858
run-make/long-linker-command-lines/Makefile
59-
run-make/lto-linkage-used-attr/Makefile
6059
run-make/lto-no-link-whole-rlib/Makefile
6160
run-make/macos-deployment-target/Makefile
6261
run-make/min-global-align/Makefile

tests/run-make/lto-linkage-used-attr/Makefile

-8
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
// Link time optimizations (LTO) used to snip away some important symbols
2+
// when setting optimization level to 3 or higher.
3+
// This is an LLVM, not a rustc bug, fixed here: https://reviews.llvm.org/D145293
4+
// This test checks that the impl_* symbols are preserved as they should.
5+
// See https://github.com/rust-lang/rust/issues/108030
6+
7+
//FIXME(Oneirical): try it on more than only-x86_64-unknown-linux-gnu
8+
9+
use run_make_support::rustc;
10+
11+
fn main() {
12+
rustc().arg("-Cdebuginfo=0").opt_level("3").input("lib.rs").run();
13+
rustc().arg("-Clto=fat").arg("-Cdebuginfo=0").opt_level("3").input("main.rs").run();
14+
}

0 commit comments

Comments
 (0)