2007-04-16 17:36:08 +00:00
|
|
|
; RUN: llvm-as < %s | llc -mtriple=i686-pc-linux-gnu -relocation-model=pic \
|
|
|
|
; RUN: -o %t -f
|
|
|
|
; RUN: grep _GLOBAL_OFFSET_TABLE_ %t
|
2007-11-14 09:18:41 +00:00
|
|
|
; RUN: grep piclabel %t | count 3
|
2007-08-15 13:36:28 +00:00
|
|
|
; RUN: grep PLT %t | count 6
|
2007-11-14 09:18:41 +00:00
|
|
|
; RUN: grep GOTOFF %t | count 14
|
2007-11-09 20:46:00 +00:00
|
|
|
; RUN: grep JTI %t | count 2
|
2007-01-12 19:20:47 +00:00
|
|
|
|
2009-06-26 22:16:49 +00:00
|
|
|
; X86-64:
|
|
|
|
; RUN: llvm-as < %s | llc -mtriple=x86_64-pc-linux-gnu -relocation-model=pic > %t
|
|
|
|
; RUN: grep {LJTI1_0(%rip)} %t
|
|
|
|
define void @bar(i32 %n.u) nounwind {
|
2007-01-12 19:20:47 +00:00
|
|
|
entry:
|
|
|
|
switch i32 %n.u, label %bb12 [i32 1, label %bb i32 2, label %bb6 i32 4, label %bb7 i32 5, label %bb8 i32 6, label %bb10 i32 7, label %bb1 i32 8, label %bb3 i32 9, label %bb4 i32 10, label %bb9 i32 11, label %bb2 i32 12, label %bb5 i32 13, label %bb11 ]
|
|
|
|
bb:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo1()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb1:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo2()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb2:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo6()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb3:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo3()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb4:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo4()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb5:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo5()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb6:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo1()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb7:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo2()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb8:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo6()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb9:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo3()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb10:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo4()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb11:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo5()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
bb12:
|
2007-01-26 08:25:06 +00:00
|
|
|
tail call void(...)* @foo6()
|
2007-01-12 19:20:47 +00:00
|
|
|
ret void
|
|
|
|
}
|
|
|
|
|
2007-01-26 08:25:06 +00:00
|
|
|
declare void @foo1(...)
|
|
|
|
declare void @foo2(...)
|
|
|
|
declare void @foo6(...)
|
|
|
|
declare void @foo3(...)
|
|
|
|
declare void @foo4(...)
|
|
|
|
declare void @foo5(...)
|