Test that prune-eh doesn't make deductions based
authorDuncan Sands <baldrick@free.fr>
Mon, 9 Jun 2008 11:28:41 +0000 (11:28 +0000)
committerDuncan Sands <baldrick@free.fr>
Mon, 9 Jun 2008 11:28:41 +0000 (11:28 +0000)
on bodies of functions with weak linkage.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52141 91177308-0d34-0410-b5e6-96231b3b80d8

test/Transforms/PruneEH/2008-06-02-Weak.ll [new file with mode: 0644]

diff --git a/test/Transforms/PruneEH/2008-06-02-Weak.ll b/test/Transforms/PruneEH/2008-06-02-Weak.ll
new file mode 100644 (file)
index 0000000..133200f
--- /dev/null
@@ -0,0 +1,12 @@
+; RUN: llvm-as < %s | opt -prune-eh | llvm-dis | not grep nounwind
+
+define weak void @f() {
+entry:
+        ret void
+}
+
+define void @g() {
+entry:
+       call void @f()
+       ret void
+}