File tree Expand file tree Collapse file tree 5 files changed +32
-17
lines changed
incr-add-rust-src-component
issue-84395-lto-embed-bitcode Expand file tree Collapse file tree 5 files changed +32
-17
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ run-make/extern-fn-reachable/Makefile
1212run-make/foreign-double-unwind/Makefile
1313run-make/foreign-exceptions/Makefile
1414run-make/issue-36710/Makefile
15- run-make/issue-84395-lto-embed-bitcode/Makefile
1615run-make/issue-88756-default-output/Makefile
1716run-make/jobserver-error/Makefile
1817run-make/libs-through-symlinks/Makefile
Original file line number Diff line number Diff line change 1- // rust-lang/rust#70924: Test that if we add rust-src component in between two
2- // incremental compiles, the compiler does not ICE on the second.
1+ // rust-lang/rust#70924: Test that if we add rust-src component in between
2+ // two incremental compiles, the compiler does not ICE on the second.
33// Remove the rust-src part of the sysroot for the *first* build.
44// Then put in a facsimile of the rust-src
55// component for the second build, in order to expose the ICE from issue #70924.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1+ // This test checks that the embed bitcode in elf created with
2+ // lto-embed-bitcode=optimized is a valid llvm bitcode module.
3+ // Otherwise, the `test.bc` file will cause an error when
4+ // `llvm-dis` attempts to disassemble it.
5+ // See https://github.com/rust-lang/rust/issues/84395
6+
7+ //@ needs-force-clang-based-tests
8+ // NOTE(#126180): This test only runs on `x86_64-gnu-debug`, because that CI job sets
9+ // RUSTBUILD_FORCE_CLANG_BASED_TESTS and only runs tests which contain "clang" in their
10+ // name.
11+
12+ use run_make_support:: llvm:: llvm_bin_dir;
13+ use run_make_support:: { cmd, env_var, rustc} ;
14+
15+ fn main ( ) {
16+ rustc ( )
17+ . input ( "test.rs" )
18+ . link_arg ( "-fuse-ld=lld" )
19+ . arg ( "linker-plugin-lto" )
20+ . linker ( & env_var ( "CLANG" ) )
21+ . link_arg ( "-Wl,--plugin-opt=-lto-embed-bitcode=optimized" )
22+ . arg ( "-Zemit-thin-lto=no" )
23+ . run ( ) ;
24+ cmd ( llvm_bin_dir ( ) . join ( "objcopy" ) )
25+ . arg ( "--dump-section" )
26+ . arg ( ".llvmbc=test.bc" )
27+ . arg ( "test" )
28+ . run ( ) ;
29+ cmd ( llvm_bin_dir ( ) . join ( "llvm-dis" ) ) . arg ( "test.bc" ) . run ( ) ;
30+ }
File renamed without changes.
You can’t perform that action at this time.
0 commit comments