• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: llvm-as < %s >%t1
2; RUN: llvm-lto -o %t2 -dso-symbol=foo1 -dso-symbol=foo2 -dso-symbol=foo3 \
3; RUN:     -dso-symbol=foo4 -dso-symbol=v1 -dso-symbol=v2 %t1 -disable-opt
4; RUN: llvm-nm %t2 | FileCheck %s
5
6target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128"
7target triple = "x86_64-unknown-linux-gnu"
8
9; CHECK: t foo1
10define linkonce_odr void @foo1() noinline {
11  ret void
12}
13
14; CHECK: W foo2
15define linkonce_odr void @foo2() noinline {
16  ret void
17}
18
19; CHECK: t foo3
20define linkonce_odr void @foo3() noinline {
21  ret void
22}
23
24; CHECK: W foo4
25define linkonce_odr void @foo4() noinline {
26  ret void
27}
28
29; CHECK: r v1
30@v1 = linkonce_odr constant i32 32
31
32; CHECK: V v2
33@v2 = linkonce_odr global i32 32
34
35declare void @f(void()*)
36
37declare void @p()
38
39define void @bar() {
40bb0:
41  call void @foo1()
42  call void @f(void()* @foo2)
43  invoke void @foo3() to label %bb1 unwind label %clean
44bb1:
45  invoke void @f(void()* @foo4) to label %bb2 unwind label %clean
46bb2:
47  ret void
48clean:
49  landingpad {i32, i32} personality void()* @p cleanup
50  ret void
51}
52