blob: 304246bca47a0858e099a35fcbc005198e7118b1 [file] [log] [blame]
Rafael Espindola33466a72014-08-21 20:28:55 +00001; RUN: llc %s -o %t.o -filetype=obj -relocation-model=pic
2; RUN: llvm-as %p/Inputs/pr19901-1.ll -o %t2.o
3; RUN: ld -shared -o %t.so -plugin %llvmshlibdir/LLVMgold.so %t2.o %t.o
Rafael Espindolaf1d2fc62014-09-03 16:16:02 +00004; RUN: llvm-readobj -t %t.so | FileCheck %s
Rafael Espindola33466a72014-08-21 20:28:55 +00005
Rafael Espindolaf1d2fc62014-09-03 16:16:02 +00006; CHECK: Symbol {
7; CHECK: Name: f
8; CHECK-NEXT: Value:
9; CHECK-NEXT: Size:
10; CHECK-NEXT: Binding: Local
11; CHECK-NEXT: Type: Function
12; CHECK-NEXT: Other: 2
13; CHECK-NEXT: Section: .text
14; CHECK-NEXT: }
Rafael Espindola33466a72014-08-21 20:28:55 +000015
16target triple = "x86_64-unknown-linux-gnu"
17define i32 @g() {
18 call void @f()
19 ret i32 0
20}
21define linkonce_odr hidden void @f() {
22 ret void
23}