blob: fa0567fc9c1ab4e3a264f11c552dfad1cf185dc6 [file] [log] [blame]
Chris Lattner413100f2006-05-17 03:57:31 +00001; Test various forms of calls.
2
3; RUN: llvm-as < %s | llc -march=ppc32 | grep 'bl ' | wc -l | grep 1 &&
4; RUN: llvm-as < %s | llc -march=ppc32 | grep 'bctrl' | wc -l | grep 1 &&
5; RUN: llvm-as < %s | llc -march=ppc32 | grep 'bla ' | wc -l | grep 1
6
7declare void %foo()
8
9void %test_direct() {
10 call void %foo()
11 ret void
12}
13
14void %test_indirect(void()* %fp) {
15 call void %fp()
16 ret void
17}
18
19void %test_abs() {
20 %fp = cast int 400 to void()*
21 call void %fp()
22 ret void
23}