summaryrefslogtreecommitdiffstats
path: root/llvm/test
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2017-06-27 15:39:40 +0000
committerCraig Topper <craig.topper@gmail.com>2017-06-27 15:39:40 +0000
commit81cbb0c2374d5c49037e818c026f9cdecacfe481 (patch)
treec7bda5cde75a67a5d177d5e4f5c9d4285bfccea2 /llvm/test
parent0a60d8581116193d254cc7ce64e29d0294f1c53f (diff)
downloadbcm5719-llvm-81cbb0c2374d5c49037e818c026f9cdecacfe481.tar.gz
bcm5719-llvm-81cbb0c2374d5c49037e818c026f9cdecacfe481.zip
[PatternMatch] Remove 64-bit or less restriction from m_SpecificInt
Not sure why this restriction existed, but it seems like we should support any size Constant here. The particular pattern in the tests is not the only use of this matcher in the tree. There's one in CodeGenPrepare and one in InstSimplify as well. Differential Revision: https://reviews.llvm.org/D34666 llvm-svn: 306417
Diffstat (limited to 'llvm/test')
-rw-r--r--llvm/test/Transforms/InstCombine/select-cmp-cttz-ctlz.ll12
1 files changed, 4 insertions, 8 deletions
diff --git a/llvm/test/Transforms/InstCombine/select-cmp-cttz-ctlz.ll b/llvm/test/Transforms/InstCombine/select-cmp-cttz-ctlz.ll
index c5547acdc8c..3ac02795b47 100644
--- a/llvm/test/Transforms/InstCombine/select-cmp-cttz-ctlz.ll
+++ b/llvm/test/Transforms/InstCombine/select-cmp-cttz-ctlz.ll
@@ -320,10 +320,8 @@ entry:
define i128 @test7(i128 %x) {
; CHECK-LABEL: @test7(
-; CHECK-NEXT: [[TMP0:%.*]] = tail call i128 @llvm.ctlz.i128(i128 [[X:%.*]], i1 true), !range !3
-; CHECK-NEXT: [[TOBOOL:%.*]] = icmp ne i128 [[X]], 0
-; CHECK-NEXT: [[COND:%.*]] = select i1 [[TOBOOL]], i128 [[TMP0]], i128 128
-; CHECK-NEXT: ret i128 [[COND]]
+; CHECK-NEXT: [[TMP1:%.*]] = tail call i128 @llvm.ctlz.i128(i128 [[X:%.*]], i1 false), !range !3
+; CHECK-NEXT: ret i128 [[TMP1]]
;
%1 = tail call i128 @llvm.ctlz.i128(i128 %x, i1 true)
%tobool = icmp ne i128 %x, 0
@@ -333,10 +331,8 @@ define i128 @test7(i128 %x) {
define i128 @test8(i128 %x) {
; CHECK-LABEL: @test8(
-; CHECK-NEXT: [[TMP0:%.*]] = tail call i128 @llvm.cttz.i128(i128 [[X:%.*]], i1 true), !range !3
-; CHECK-NEXT: [[TOBOOL:%.*]] = icmp ne i128 [[X]], 0
-; CHECK-NEXT: [[COND:%.*]] = select i1 [[TOBOOL]], i128 [[TMP0]], i128 128
-; CHECK-NEXT: ret i128 [[COND]]
+; CHECK-NEXT: [[TMP1:%.*]] = tail call i128 @llvm.cttz.i128(i128 [[X:%.*]], i1 false), !range !3
+; CHECK-NEXT: ret i128 [[TMP1]]
;
%1 = tail call i128 @llvm.cttz.i128(i128 %x, i1 true)
%tobool = icmp ne i128 %x, 0
OpenPOWER on IntegriCloud