aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen/Generic/2004-02-08-UnwindSupport.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/Generic/2004-02-08-UnwindSupport.ll')
-rw-r--r--test/CodeGen/Generic/2004-02-08-UnwindSupport.ll17
1 files changed, 17 insertions, 0 deletions
diff --git a/test/CodeGen/Generic/2004-02-08-UnwindSupport.ll b/test/CodeGen/Generic/2004-02-08-UnwindSupport.ll
new file mode 100644
index 0000000000..10d40693d8
--- /dev/null
+++ b/test/CodeGen/Generic/2004-02-08-UnwindSupport.ll
@@ -0,0 +1,17 @@
+; RUN: llvm-as < %s | llc -enable-correct-eh-support
+
+define i32 @test() {
+ unwind
+}
+
+define i32 @main() {
+ %X = invoke i32 @test( )
+ to label %cont unwind label %EH ; <i32> [#uses=0]
+
+cont: ; preds = %0
+ ret i32 1
+
+EH: ; preds = %0
+ ret i32 0
+}
+