Loading llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-ne-to-icmp-ugt.ll +10 −0 Original line number Diff line number Diff line Loading @@ -90,6 +90,16 @@ define <3 x i1> @p3_vec_splat_undef(<3 x i8> %x) { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef(<3 x i8> %x) { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[TMP1:%.*]] = icmp ugt <3 x i8> [[X:%.*]], <i8 -1, i8 undef, i8 3> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %tmp0 = and <3 x i8> %x, <i8 -1, i8 undef, i8 3> %ret = icmp ne <3 x i8> %tmp0, %x ret <3 x i1> %ret } ; ============================================================================ ; ; Commutativity tests. ; ============================================================================ ; Loading llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-sgt-to-icmp-sgt.ll +12 −0 Original line number Diff line number Diff line Loading @@ -85,6 +85,18 @@ define <3 x i1> @p3_vec_splat_undef() { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef() { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[X:%.*]] = call <3 x i8> @gen3x8() ; CHECK-NEXT: [[TMP1:%.*]] = icmp sgt <3 x i8> [[X]], <i8 15, i8 3, i8 undef> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %x = call <3 x i8> @gen3x8() %tmp0 = and <3 x i8> %x, <i8 15, i8 3, i8 undef> %ret = icmp sgt <3 x i8> %x, %tmp0 ret <3 x i1> %ret } ; ============================================================================ ; ; One-use tests. We don't care about multi-uses here. ; ============================================================================ ; Loading llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-slt-to-icmp-sgt.ll +10 −0 Original line number Diff line number Diff line Loading @@ -69,6 +69,16 @@ define <3 x i1> @p3_vec_splat_undef(<3 x i8> %x) { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef(<3 x i8> %x) { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[TMP1:%.*]] = icmp sgt <3 x i8> [[X:%.*]], <i8 undef, i8 15, i8 3> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %tmp0 = and <3 x i8> %x, <i8 undef, i8 15, i8 3> %ret = icmp slt <3 x i8> %tmp0, %x ret <3 x i1> %ret } ; ============================================================================ ; ; One-use tests. We don't care about multi-uses here. ; ============================================================================ ; Loading llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-ugt-to-icmp-ugt.ll +12 −0 Original line number Diff line number Diff line Loading @@ -108,6 +108,18 @@ define <3 x i1> @p3_vec_splat_undef() { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef() { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[X:%.*]] = call <3 x i8> @gen3x8() ; CHECK-NEXT: [[TMP1:%.*]] = icmp ugt <3 x i8> [[X]], <i8 3, i8 undef, i8 15> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %x = call <3 x i8> @gen3x8() %tmp0 = and <3 x i8> %x, <i8 3, i8 undef, i8 15> %ret = icmp ugt <3 x i8> %x, %tmp0 ret <3 x i1> %ret } ; ============================================================================ ; ; Commutativity tests. ; ============================================================================ ; Loading llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-ult-to-icmp-ugt.ll +10 −0 Original line number Diff line number Diff line Loading @@ -91,6 +91,16 @@ define <3 x i1> @p3_vec_splat_undef(<3 x i8> %x) { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef(<3 x i8> %x) { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[TMP1:%.*]] = icmp ugt <3 x i8> [[X:%.*]], <i8 7, i8 31, i8 undef> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %tmp0 = and <3 x i8> %x, <i8 7, i8 31, i8 undef> %ret = icmp ult <3 x i8> %tmp0, %x ret <3 x i1> %ret } ; ============================================================================ ; ; Commutativity tests. ; ============================================================================ ; Loading Loading
llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-ne-to-icmp-ugt.ll +10 −0 Original line number Diff line number Diff line Loading @@ -90,6 +90,16 @@ define <3 x i1> @p3_vec_splat_undef(<3 x i8> %x) { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef(<3 x i8> %x) { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[TMP1:%.*]] = icmp ugt <3 x i8> [[X:%.*]], <i8 -1, i8 undef, i8 3> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %tmp0 = and <3 x i8> %x, <i8 -1, i8 undef, i8 3> %ret = icmp ne <3 x i8> %tmp0, %x ret <3 x i1> %ret } ; ============================================================================ ; ; Commutativity tests. ; ============================================================================ ; Loading
llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-sgt-to-icmp-sgt.ll +12 −0 Original line number Diff line number Diff line Loading @@ -85,6 +85,18 @@ define <3 x i1> @p3_vec_splat_undef() { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef() { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[X:%.*]] = call <3 x i8> @gen3x8() ; CHECK-NEXT: [[TMP1:%.*]] = icmp sgt <3 x i8> [[X]], <i8 15, i8 3, i8 undef> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %x = call <3 x i8> @gen3x8() %tmp0 = and <3 x i8> %x, <i8 15, i8 3, i8 undef> %ret = icmp sgt <3 x i8> %x, %tmp0 ret <3 x i1> %ret } ; ============================================================================ ; ; One-use tests. We don't care about multi-uses here. ; ============================================================================ ; Loading
llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-slt-to-icmp-sgt.ll +10 −0 Original line number Diff line number Diff line Loading @@ -69,6 +69,16 @@ define <3 x i1> @p3_vec_splat_undef(<3 x i8> %x) { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef(<3 x i8> %x) { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[TMP1:%.*]] = icmp sgt <3 x i8> [[X:%.*]], <i8 undef, i8 15, i8 3> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %tmp0 = and <3 x i8> %x, <i8 undef, i8 15, i8 3> %ret = icmp slt <3 x i8> %tmp0, %x ret <3 x i1> %ret } ; ============================================================================ ; ; One-use tests. We don't care about multi-uses here. ; ============================================================================ ; Loading
llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-ugt-to-icmp-ugt.ll +12 −0 Original line number Diff line number Diff line Loading @@ -108,6 +108,18 @@ define <3 x i1> @p3_vec_splat_undef() { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef() { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[X:%.*]] = call <3 x i8> @gen3x8() ; CHECK-NEXT: [[TMP1:%.*]] = icmp ugt <3 x i8> [[X]], <i8 3, i8 undef, i8 15> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %x = call <3 x i8> @gen3x8() %tmp0 = and <3 x i8> %x, <i8 3, i8 undef, i8 15> %ret = icmp ugt <3 x i8> %x, %tmp0 ret <3 x i1> %ret } ; ============================================================================ ; ; Commutativity tests. ; ============================================================================ ; Loading
llvm/test/Transforms/InstCombine/canonicalize-constant-low-bit-mask-and-icmp-ult-to-icmp-ugt.ll +10 −0 Original line number Diff line number Diff line Loading @@ -91,6 +91,16 @@ define <3 x i1> @p3_vec_splat_undef(<3 x i8> %x) { ret <3 x i1> %ret } define <3 x i1> @p3_vec_nonsplat_undef(<3 x i8> %x) { ; CHECK-LABEL: @p3_vec_nonsplat_undef( ; CHECK-NEXT: [[TMP1:%.*]] = icmp ugt <3 x i8> [[X:%.*]], <i8 7, i8 31, i8 undef> ; CHECK-NEXT: ret <3 x i1> [[TMP1]] ; %tmp0 = and <3 x i8> %x, <i8 7, i8 31, i8 undef> %ret = icmp ult <3 x i8> %tmp0, %x ret <3 x i1> %ret } ; ============================================================================ ; ; Commutativity tests. ; ============================================================================ ; Loading