new testcase
[oota-llvm.git] / test / Feature / callingconventions.ll
1 ; RUN: llvm-as %s -o - | llvm-dis > %t1.ll
2 ; RUN: llvm-as %t1.ll -o - | llvm-dis > %t2.ll
3 ; RUN: diff %t1.ll %t2.ll
4
5 fastcc void %foo() {
6   ret void
7 }
8
9 coldcc void %bar() {
10   call fastcc void %foo()
11   ret void
12 }
13
14
15 cc0 void %foo2() {
16   ret void
17 }
18
19 coldcc void %bar2() {
20   call fastcc void %foo()
21   ret void
22 }
23
24 cc42 void %bar3() {
25   invoke fastcc void %foo() to label %Ok unwind label %U
26 Ok:
27   ret void
28 U:
29   unwind
30 }
31
32
33 void %bar4() {
34   call cc42 void %bar()
35   invoke cc42 void %bar3() to label %Ok unwind label %U
36 Ok:
37   ret void
38 U:
39   unwind
40 }
41
42