Fix a scalability issue with complex ConstantExprs.
[oota-llvm.git] / test / Transforms / GlobalDCE / 2003-07-01-SelfReference.ll
index e306d9a4aff1d774b4876c716c5873424c378626..738ec43aaeb1719b5bc31c76cfcd994511e317a5 100644 (file)
@@ -1,11 +1,11 @@
 ; distilled from 255.vortex
-; RUN: llvm-as < %s | opt -globaldce | llvm-dis | not grep testfunc
+; RUN: opt < %s -globaldce -S | not grep testfunc
 
-implementation
+declare i1 ()* @getfunc()
 
-declare bool()* %getfunc()
-internal bool %testfunc() {
-       %F = call bool()*()* %getfunc()
-       %c = seteq bool()* %F, %testfunc
-       ret bool %c
+define internal i1 @testfunc() {
+        %F = call i1 ()* ()* @getfunc( )                ; <i1 ()*> [#uses=1]
+        %c = icmp eq i1 ()* %F, @testfunc               ; <i1> [#uses=1]
+        ret i1 %c
 }
+