Use the llvm-upgrade program to upgrade llvm assembly.
[oota-llvm.git] / test / Transforms / SimplifyCFG / InvokeEliminate.ll
1 ; This testcase checks to see if the simplifycfg pass is converting invoke
2 ; instructions to call instructions if the handler just rethrows the exception.
3
4 ; If this test is successful, the function should be reduced to 'call; ret'
5
6 ; RUN: llvm-upgrade < %s | llvm-as | opt -simplifycfg | llvm-dis | not egrep 'invoke|br'
7
8 declare void %bar()
9
10 int %test() {
11         invoke void %bar() to label %Ok except label %Rethrow
12 Ok:
13         ret int 0
14 Rethrow:
15         unwind
16 }
17