aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/Assembler/ConstantExprFold.llx3
-rw-r--r--test/Transforms/InstCombine/2007-12-10-ConstFoldCompare.ll9
2 files changed, 9 insertions, 3 deletions
diff --git a/test/Assembler/ConstantExprFold.llx b/test/Assembler/ConstantExprFold.llx
index b4d779d..0285743 100644
--- a/test/Assembler/ConstantExprFold.llx
+++ b/test/Assembler/ConstantExprFold.llx
@@ -24,6 +24,3 @@ global bool setlt (int* getelementptr (%Ty* %B, long 0, uint 0),
int* getelementptr (%Ty* %B, long 0, uint 1)) ; true
;global bool setne (long* %A, long* cast (%Ty* %B to long*)) ; true
-global bool seteq ({ short }* cast (int 1 to { short }*), { short }* null)
-global bool setlt ({ short }* cast (int 1 to { short }*), { short }* cast (int 2 to { short }*))
-
diff --git a/test/Transforms/InstCombine/2007-12-10-ConstFoldCompare.ll b/test/Transforms/InstCombine/2007-12-10-ConstFoldCompare.ll
new file mode 100644
index 0000000..80df6fb
--- /dev/null
+++ b/test/Transforms/InstCombine/2007-12-10-ConstFoldCompare.ll
@@ -0,0 +1,9 @@
+target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:32:64-f32:32:32-f64:32:64-v64:64:64-v128:128:128-a0:0:64-f80:32:32"
+target triple = "i686-pc-linux-gnu"
+; RUN: llvm-as < %s | opt -instcombine | llvm-dis | not grep {ret i1 0}
+; PR1850
+
+define i1 @test() {
+ %cond = icmp ule i8* inttoptr (i64 4294967297 to i8*), inttoptr (i64 5 to i8*)
+ ret i1 %cond
+}