[llvm] 6147501 - [InstSimplify] Add a test for folding comparison with a undef vector (NFC)
Juneyoung Lee via llvm-commits
llvm-commits at lists.llvm.org
Sat Apr 3 21:47:07 PDT 2021
Author: Juneyoung Lee
Date: 2021-04-04T13:46:56+09:00
New Revision: 6147501617f0a9e7d81bc5fa0182ba669bc2e520
URL: https://github.com/llvm/llvm-project/commit/6147501617f0a9e7d81bc5fa0182ba669bc2e520
DIFF: https://github.com/llvm/llvm-project/commit/6147501617f0a9e7d81bc5fa0182ba669bc2e520.diff
LOG: [InstSimplify] Add a test for folding comparison with a undef vector (NFC)
This is to fix https://reviews.llvm.org/D93990#2666922
Added:
Modified:
llvm/test/Transforms/InstSimplify/icmp-constant.ll
Removed:
################################################################################
diff --git a/llvm/test/Transforms/InstSimplify/icmp-constant.ll b/llvm/test/Transforms/InstSimplify/icmp-constant.ll
index 9db63e64b914..dbbce4b44e58 100644
--- a/llvm/test/Transforms/InstSimplify/icmp-constant.ll
+++ b/llvm/test/Transforms/InstSimplify/icmp-constant.ll
@@ -1065,3 +1065,13 @@ bb3:
%m = mul nuw i8 %x, 0
br label %bb2
}
+
+
+define <2 x i1> @heterogeneous_constvector(<2 x i8> %x) {
+; CHECK-LABEL: @heterogeneous_constvector(
+; CHECK-NEXT: [[C:%.*]] = icmp ult <2 x i8> [[X:%.*]], <i8 undef, i8 poison>
+; CHECK-NEXT: ret <2 x i1> [[C]]
+;
+ %c = icmp ult <2 x i8> %x, <i8 undef, i8 poison>
+ ret <2 x i1> %c
+}
More information about the llvm-commits
mailing list