xref: /llvm-project/llvm/test/tools/gold/X86/thinlto-emit-llvm.ll (revision 0b1914e83a03be926569892c17ca743c5ea46d1f)
1; RUN: llvm-as %p/Inputs/emit-llvm.foo.ll -o %t.foo.bc
2; RUN: llvm-as %p/Inputs/emit-llvm.bar.ll -o %t.bar.bc
3; RUN: %gold -plugin %llvmshlibdir/LLVMgold%shlibext --shared -plugin-opt thinlto -plugin-opt emit-llvm -m elf_x86_64 %t.foo.bc %t.bar.bc -o %t.bc
4; RUN: llvm-dis %t.bc1 -o - | FileCheck --check-prefix=CHECK-BC1 %s
5; RUN: llvm-dis %t.bc2 -o - | FileCheck --check-prefix=CHECK-BC2 %s
6
7target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
8target triple = "x86_64-unknown-linux-gnu"
9
10; CHECK-BC1: define dso_local i32 @_Z3foov()
11define dso_local i32 @_Z3foov() {
12    ret i32 0
13}
14; CHECK-BC2: define dso_local i32 @_Z3barv()
15define dso_local i32 @_Z3barv() {
16    ret i32 0
17}
18