blob: 89d76a8492f7b75adbbadd60037fcafead540274 [file] [log] [blame]
Dan Gohmanf17a25c2007-07-18 16:29:46 +00001; 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 | \
7; RUN: not egrep {\\(invoke\\)|\\(br\\)}
8
9declare void %bar()
10
11int %test() {
12 invoke void %bar() to label %Ok except label %Rethrow
13Ok:
14 ret int 0
15Rethrow:
16 unwind
17}
18