[clang] [CIR][AArch64] Lower NEON zip1/2 elements intrinsics (PR #194311)
via cfe-commits
cfe-commits at lists.llvm.org
Mon Apr 27 01:20:28 PDT 2026
llvmbot wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-clang
Author: Jiahao Guo (E00N777)
<details>
<summary>Changes</summary>
### Summary
part of : https://github.com/llvm/llvm-project/issues/185382
This is a follow up : https://github.com/llvm/llvm-project/pull/193658
Lower zip1 and zip2 intrinsics in https://arm-software.github.io/acle/neon_intrinsics/advsimd.html#zip-elements
All the intrinsics are handled inline in `llvm-project/build/lib/clang/23/include/arm_neon.h` like:
```
#ifdef __LITTLE_ENDIAN__
__ai __attribute__((target("neon"))) int8x8_t vzip1_s8(int8x8_t __p0, int8x8_t __p1) {
int8x8_t __ret;
__ret = __builtin_shufflevector(__p0, __p1, 0, 8, 1, 9, 2, 10, 3, 11);
return __ret;
}
#else
__ai __attribute__((target("neon"))) int8x8_t vzip1_s8(int8x8_t __p0, int8x8_t __p1) {
int8x8_t __ret;
int8x8_t __rev0; __rev0 = __builtin_shufflevector(__p0, __p0, __lane_reverse_64_8);
int8x8_t __rev1; __rev1 = __builtin_shufflevector(__p1, __p1, __lane_reverse_64_8);
__ret = __builtin_shufflevector(__rev0, __rev1, 0, 8, 1, 9, 2, 10, 3, 11);
__ret = __builtin_shufflevector(__ret, __ret, __lane_reverse_64_8);
return __ret;
}
#endif
```
So no additional special lowering logic is needed.
---
Patch is 53.82 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/194311.diff
4 Files Affected:
- (modified) clang/test/CodeGen/AArch64/fp8-intrinsics/acle_neon_fp8_untyped.c (-40)
- (modified) clang/test/CodeGen/AArch64/neon-perm.c (-420)
- (modified) clang/test/CodeGen/AArch64/neon/intrinsics.c (+533)
- (modified) clang/test/CodeGen/AArch64/poly64.c (-20)
``````````diff
diff --git a/clang/test/CodeGen/AArch64/fp8-intrinsics/acle_neon_fp8_untyped.c b/clang/test/CodeGen/AArch64/fp8-intrinsics/acle_neon_fp8_untyped.c
index dbd1fb23644d9..3e4607c835250 100644
--- a/clang/test/CodeGen/AArch64/fp8-intrinsics/acle_neon_fp8_untyped.c
+++ b/clang/test/CodeGen/AArch64/fp8-intrinsics/acle_neon_fp8_untyped.c
@@ -703,26 +703,6 @@ mfloat8x16_t test_vtrn1q_mf8(mfloat8x16_t a, mfloat8x16_t b) {
return vtrn1q_mf8(a, b);
}
-// CHECK-LABEL: define dso_local <8 x i8> @test_vzip1_mf8(
-// CHECK-SAME: <8 x i8> [[A:%.*]], <8 x i8> [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i8> [[A]], <8 x i8> [[B]], <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
-// CHECK-NEXT: ret <8 x i8> [[SHUFFLE_I]]
-//
-mfloat8x8_t test_vzip1_mf8(mfloat8x8_t a, mfloat8x8_t b) {
- return vzip1_mf8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <16 x i8> @test_vzip1q_mf8(
-// CHECK-SAME: <16 x i8> [[A:%.*]], <16 x i8> [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <16 x i8> [[A]], <16 x i8> [[B]], <16 x i32> <i32 0, i32 16, i32 1, i32 17, i32 2, i32 18, i32 3, i32 19, i32 4, i32 20, i32 5, i32 21, i32 6, i32 22, i32 7, i32 23>
-// CHECK-NEXT: ret <16 x i8> [[SHUFFLE_I]]
-//
-mfloat8x16_t test_vzip1q_mf8(mfloat8x16_t a, mfloat8x16_t b) {
- return vzip1q_mf8(a, b);
-}
-
// CHECK-LABEL: define dso_local <8 x i8> @test_vuzp1_mf8(
// CHECK-SAME: <8 x i8> [[A:%.*]], <8 x i8> [[B:%.*]]) #[[ATTR0]] {
// CHECK-NEXT: [[ENTRY:.*:]]
@@ -763,26 +743,6 @@ mfloat8x16_t test_vtrn2q_mf8(mfloat8x16_t a, mfloat8x16_t b) {
return vtrn2q_mf8(a, b);
}
-// CHECK-LABEL: define dso_local <8 x i8> @test_vzip2_mf8(
-// CHECK-SAME: <8 x i8> [[A:%.*]], <8 x i8> [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i8> [[A]], <8 x i8> [[B]], <8 x i32> <i32 4, i32 12, i32 5, i32 13, i32 6, i32 14, i32 7, i32 15>
-// CHECK-NEXT: ret <8 x i8> [[SHUFFLE_I]]
-//
-mfloat8x8_t test_vzip2_mf8(mfloat8x8_t a, mfloat8x8_t b) {
- return vzip2_mf8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <16 x i8> @test_vzip2q_mf8(
-// CHECK-SAME: <16 x i8> [[A:%.*]], <16 x i8> [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <16 x i8> [[A]], <16 x i8> [[B]], <16 x i32> <i32 8, i32 24, i32 9, i32 25, i32 10, i32 26, i32 11, i32 27, i32 12, i32 28, i32 13, i32 29, i32 14, i32 30, i32 15, i32 31>
-// CHECK-NEXT: ret <16 x i8> [[SHUFFLE_I]]
-//
-mfloat8x16_t test_vzip2q_mf8(mfloat8x16_t a, mfloat8x16_t b) {
- return vzip2q_mf8(a, b);
-}
-
// CHECK-LABEL: define dso_local <8 x i8> @test_vuzp2_mf8(
// CHECK-SAME: <8 x i8> [[A:%.*]], <8 x i8> [[B:%.*]]) #[[ATTR0]] {
// CHECK-NEXT: [[ENTRY:.*:]]
diff --git a/clang/test/CodeGen/AArch64/neon-perm.c b/clang/test/CodeGen/AArch64/neon-perm.c
index 61b24c55a39a3..3eb9a7d3d8dab 100644
--- a/clang/test/CodeGen/AArch64/neon-perm.c
+++ b/clang/test/CodeGen/AArch64/neon-perm.c
@@ -426,426 +426,6 @@ poly16x8_t test_vuzp2q_p16(poly16x8_t a, poly16x8_t b) {
return vuzp2q_p16(a, b);
}
-// CHECK-LABEL: define dso_local <8 x i8> @test_vzip1_s8(
-// CHECK-SAME: <8 x i8> noundef [[A:%.*]], <8 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i8> [[A]], <8 x i8> [[B]], <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
-// CHECK-NEXT: ret <8 x i8> [[SHUFFLE_I]]
-//
-int8x8_t test_vzip1_s8(int8x8_t a, int8x8_t b) {
- return vzip1_s8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <16 x i8> @test_vzip1q_s8(
-// CHECK-SAME: <16 x i8> noundef [[A:%.*]], <16 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <16 x i8> [[A]], <16 x i8> [[B]], <16 x i32> <i32 0, i32 16, i32 1, i32 17, i32 2, i32 18, i32 3, i32 19, i32 4, i32 20, i32 5, i32 21, i32 6, i32 22, i32 7, i32 23>
-// CHECK-NEXT: ret <16 x i8> [[SHUFFLE_I]]
-//
-int8x16_t test_vzip1q_s8(int8x16_t a, int8x16_t b) {
- return vzip1q_s8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i16> @test_vzip1_s16(
-// CHECK-SAME: <4 x i16> noundef [[A:%.*]], <4 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i16> [[A]], <4 x i16> [[B]], <4 x i32> <i32 0, i32 4, i32 1, i32 5>
-// CHECK-NEXT: ret <4 x i16> [[SHUFFLE_I]]
-//
-int16x4_t test_vzip1_s16(int16x4_t a, int16x4_t b) {
- return vzip1_s16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i16> @test_vzip1q_s16(
-// CHECK-SAME: <8 x i16> noundef [[A:%.*]], <8 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i16> [[A]], <8 x i16> [[B]], <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
-// CHECK-NEXT: ret <8 x i16> [[SHUFFLE_I]]
-//
-int16x8_t test_vzip1q_s16(int16x8_t a, int16x8_t b) {
- return vzip1q_s16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i32> @test_vzip1_s32(
-// CHECK-SAME: <2 x i32> noundef [[A:%.*]], <2 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i32> [[A]], <2 x i32> [[B]], <2 x i32> <i32 0, i32 2>
-// CHECK-NEXT: ret <2 x i32> [[SHUFFLE_I]]
-//
-int32x2_t test_vzip1_s32(int32x2_t a, int32x2_t b) {
- return vzip1_s32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i32> @test_vzip1q_s32(
-// CHECK-SAME: <4 x i32> noundef [[A:%.*]], <4 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i32> [[A]], <4 x i32> [[B]], <4 x i32> <i32 0, i32 4, i32 1, i32 5>
-// CHECK-NEXT: ret <4 x i32> [[SHUFFLE_I]]
-//
-int32x4_t test_vzip1q_s32(int32x4_t a, int32x4_t b) {
- return vzip1q_s32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i64> @test_vzip1q_s64(
-// CHECK-SAME: <2 x i64> noundef [[A:%.*]], <2 x i64> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i64> [[A]], <2 x i64> [[B]], <2 x i32> <i32 0, i32 2>
-// CHECK-NEXT: ret <2 x i64> [[SHUFFLE_I]]
-//
-int64x2_t test_vzip1q_s64(int64x2_t a, int64x2_t b) {
- return vzip1q_s64(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i8> @test_vzip1_u8(
-// CHECK-SAME: <8 x i8> noundef [[A:%.*]], <8 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i8> [[A]], <8 x i8> [[B]], <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
-// CHECK-NEXT: ret <8 x i8> [[SHUFFLE_I]]
-//
-uint8x8_t test_vzip1_u8(uint8x8_t a, uint8x8_t b) {
- return vzip1_u8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <16 x i8> @test_vzip1q_u8(
-// CHECK-SAME: <16 x i8> noundef [[A:%.*]], <16 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <16 x i8> [[A]], <16 x i8> [[B]], <16 x i32> <i32 0, i32 16, i32 1, i32 17, i32 2, i32 18, i32 3, i32 19, i32 4, i32 20, i32 5, i32 21, i32 6, i32 22, i32 7, i32 23>
-// CHECK-NEXT: ret <16 x i8> [[SHUFFLE_I]]
-//
-uint8x16_t test_vzip1q_u8(uint8x16_t a, uint8x16_t b) {
- return vzip1q_u8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i16> @test_vzip1_u16(
-// CHECK-SAME: <4 x i16> noundef [[A:%.*]], <4 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i16> [[A]], <4 x i16> [[B]], <4 x i32> <i32 0, i32 4, i32 1, i32 5>
-// CHECK-NEXT: ret <4 x i16> [[SHUFFLE_I]]
-//
-uint16x4_t test_vzip1_u16(uint16x4_t a, uint16x4_t b) {
- return vzip1_u16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i16> @test_vzip1q_u16(
-// CHECK-SAME: <8 x i16> noundef [[A:%.*]], <8 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i16> [[A]], <8 x i16> [[B]], <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
-// CHECK-NEXT: ret <8 x i16> [[SHUFFLE_I]]
-//
-uint16x8_t test_vzip1q_u16(uint16x8_t a, uint16x8_t b) {
- return vzip1q_u16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i32> @test_vzip1_u32(
-// CHECK-SAME: <2 x i32> noundef [[A:%.*]], <2 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i32> [[A]], <2 x i32> [[B]], <2 x i32> <i32 0, i32 2>
-// CHECK-NEXT: ret <2 x i32> [[SHUFFLE_I]]
-//
-uint32x2_t test_vzip1_u32(uint32x2_t a, uint32x2_t b) {
- return vzip1_u32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i32> @test_vzip1q_u32(
-// CHECK-SAME: <4 x i32> noundef [[A:%.*]], <4 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i32> [[A]], <4 x i32> [[B]], <4 x i32> <i32 0, i32 4, i32 1, i32 5>
-// CHECK-NEXT: ret <4 x i32> [[SHUFFLE_I]]
-//
-uint32x4_t test_vzip1q_u32(uint32x4_t a, uint32x4_t b) {
- return vzip1q_u32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i64> @test_vzip1q_u64(
-// CHECK-SAME: <2 x i64> noundef [[A:%.*]], <2 x i64> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i64> [[A]], <2 x i64> [[B]], <2 x i32> <i32 0, i32 2>
-// CHECK-NEXT: ret <2 x i64> [[SHUFFLE_I]]
-//
-uint64x2_t test_vzip1q_u64(uint64x2_t a, uint64x2_t b) {
- return vzip1q_u64(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x float> @test_vzip1_f32(
-// CHECK-SAME: <2 x float> noundef [[A:%.*]], <2 x float> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x float> [[A]], <2 x float> [[B]], <2 x i32> <i32 0, i32 2>
-// CHECK-NEXT: ret <2 x float> [[SHUFFLE_I]]
-//
-float32x2_t test_vzip1_f32(float32x2_t a, float32x2_t b) {
- return vzip1_f32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x float> @test_vzip1q_f32(
-// CHECK-SAME: <4 x float> noundef [[A:%.*]], <4 x float> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x float> [[A]], <4 x float> [[B]], <4 x i32> <i32 0, i32 4, i32 1, i32 5>
-// CHECK-NEXT: ret <4 x float> [[SHUFFLE_I]]
-//
-float32x4_t test_vzip1q_f32(float32x4_t a, float32x4_t b) {
- return vzip1q_f32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x double> @test_vzip1q_f64(
-// CHECK-SAME: <2 x double> noundef [[A:%.*]], <2 x double> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x double> [[A]], <2 x double> [[B]], <2 x i32> <i32 0, i32 2>
-// CHECK-NEXT: ret <2 x double> [[SHUFFLE_I]]
-//
-float64x2_t test_vzip1q_f64(float64x2_t a, float64x2_t b) {
- return vzip1q_f64(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i8> @test_vzip1_p8(
-// CHECK-SAME: <8 x i8> noundef [[A:%.*]], <8 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i8> [[A]], <8 x i8> [[B]], <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
-// CHECK-NEXT: ret <8 x i8> [[SHUFFLE_I]]
-//
-poly8x8_t test_vzip1_p8(poly8x8_t a, poly8x8_t b) {
- return vzip1_p8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <16 x i8> @test_vzip1q_p8(
-// CHECK-SAME: <16 x i8> noundef [[A:%.*]], <16 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <16 x i8> [[A]], <16 x i8> [[B]], <16 x i32> <i32 0, i32 16, i32 1, i32 17, i32 2, i32 18, i32 3, i32 19, i32 4, i32 20, i32 5, i32 21, i32 6, i32 22, i32 7, i32 23>
-// CHECK-NEXT: ret <16 x i8> [[SHUFFLE_I]]
-//
-poly8x16_t test_vzip1q_p8(poly8x16_t a, poly8x16_t b) {
- return vzip1q_p8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i16> @test_vzip1_p16(
-// CHECK-SAME: <4 x i16> noundef [[A:%.*]], <4 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i16> [[A]], <4 x i16> [[B]], <4 x i32> <i32 0, i32 4, i32 1, i32 5>
-// CHECK-NEXT: ret <4 x i16> [[SHUFFLE_I]]
-//
-poly16x4_t test_vzip1_p16(poly16x4_t a, poly16x4_t b) {
- return vzip1_p16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i16> @test_vzip1q_p16(
-// CHECK-SAME: <8 x i16> noundef [[A:%.*]], <8 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i16> [[A]], <8 x i16> [[B]], <8 x i32> <i32 0, i32 8, i32 1, i32 9, i32 2, i32 10, i32 3, i32 11>
-// CHECK-NEXT: ret <8 x i16> [[SHUFFLE_I]]
-//
-poly16x8_t test_vzip1q_p16(poly16x8_t a, poly16x8_t b) {
- return vzip1q_p16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i8> @test_vzip2_s8(
-// CHECK-SAME: <8 x i8> noundef [[A:%.*]], <8 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i8> [[A]], <8 x i8> [[B]], <8 x i32> <i32 4, i32 12, i32 5, i32 13, i32 6, i32 14, i32 7, i32 15>
-// CHECK-NEXT: ret <8 x i8> [[SHUFFLE_I]]
-//
-int8x8_t test_vzip2_s8(int8x8_t a, int8x8_t b) {
- return vzip2_s8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <16 x i8> @test_vzip2q_s8(
-// CHECK-SAME: <16 x i8> noundef [[A:%.*]], <16 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <16 x i8> [[A]], <16 x i8> [[B]], <16 x i32> <i32 8, i32 24, i32 9, i32 25, i32 10, i32 26, i32 11, i32 27, i32 12, i32 28, i32 13, i32 29, i32 14, i32 30, i32 15, i32 31>
-// CHECK-NEXT: ret <16 x i8> [[SHUFFLE_I]]
-//
-int8x16_t test_vzip2q_s8(int8x16_t a, int8x16_t b) {
- return vzip2q_s8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i16> @test_vzip2_s16(
-// CHECK-SAME: <4 x i16> noundef [[A:%.*]], <4 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i16> [[A]], <4 x i16> [[B]], <4 x i32> <i32 2, i32 6, i32 3, i32 7>
-// CHECK-NEXT: ret <4 x i16> [[SHUFFLE_I]]
-//
-int16x4_t test_vzip2_s16(int16x4_t a, int16x4_t b) {
- return vzip2_s16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i16> @test_vzip2q_s16(
-// CHECK-SAME: <8 x i16> noundef [[A:%.*]], <8 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i16> [[A]], <8 x i16> [[B]], <8 x i32> <i32 4, i32 12, i32 5, i32 13, i32 6, i32 14, i32 7, i32 15>
-// CHECK-NEXT: ret <8 x i16> [[SHUFFLE_I]]
-//
-int16x8_t test_vzip2q_s16(int16x8_t a, int16x8_t b) {
- return vzip2q_s16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i32> @test_vzip2_s32(
-// CHECK-SAME: <2 x i32> noundef [[A:%.*]], <2 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i32> [[A]], <2 x i32> [[B]], <2 x i32> <i32 1, i32 3>
-// CHECK-NEXT: ret <2 x i32> [[SHUFFLE_I]]
-//
-int32x2_t test_vzip2_s32(int32x2_t a, int32x2_t b) {
- return vzip2_s32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i32> @test_vzip2q_s32(
-// CHECK-SAME: <4 x i32> noundef [[A:%.*]], <4 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i32> [[A]], <4 x i32> [[B]], <4 x i32> <i32 2, i32 6, i32 3, i32 7>
-// CHECK-NEXT: ret <4 x i32> [[SHUFFLE_I]]
-//
-int32x4_t test_vzip2q_s32(int32x4_t a, int32x4_t b) {
- return vzip2q_s32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i64> @test_vzip2q_s64(
-// CHECK-SAME: <2 x i64> noundef [[A:%.*]], <2 x i64> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i64> [[A]], <2 x i64> [[B]], <2 x i32> <i32 1, i32 3>
-// CHECK-NEXT: ret <2 x i64> [[SHUFFLE_I]]
-//
-int64x2_t test_vzip2q_s64(int64x2_t a, int64x2_t b) {
- return vzip2q_s64(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i8> @test_vzip2_u8(
-// CHECK-SAME: <8 x i8> noundef [[A:%.*]], <8 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i8> [[A]], <8 x i8> [[B]], <8 x i32> <i32 4, i32 12, i32 5, i32 13, i32 6, i32 14, i32 7, i32 15>
-// CHECK-NEXT: ret <8 x i8> [[SHUFFLE_I]]
-//
-uint8x8_t test_vzip2_u8(uint8x8_t a, uint8x8_t b) {
- return vzip2_u8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <16 x i8> @test_vzip2q_u8(
-// CHECK-SAME: <16 x i8> noundef [[A:%.*]], <16 x i8> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <16 x i8> [[A]], <16 x i8> [[B]], <16 x i32> <i32 8, i32 24, i32 9, i32 25, i32 10, i32 26, i32 11, i32 27, i32 12, i32 28, i32 13, i32 29, i32 14, i32 30, i32 15, i32 31>
-// CHECK-NEXT: ret <16 x i8> [[SHUFFLE_I]]
-//
-uint8x16_t test_vzip2q_u8(uint8x16_t a, uint8x16_t b) {
- return vzip2q_u8(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i16> @test_vzip2_u16(
-// CHECK-SAME: <4 x i16> noundef [[A:%.*]], <4 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i16> [[A]], <4 x i16> [[B]], <4 x i32> <i32 2, i32 6, i32 3, i32 7>
-// CHECK-NEXT: ret <4 x i16> [[SHUFFLE_I]]
-//
-uint16x4_t test_vzip2_u16(uint16x4_t a, uint16x4_t b) {
- return vzip2_u16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <8 x i16> @test_vzip2q_u16(
-// CHECK-SAME: <8 x i16> noundef [[A:%.*]], <8 x i16> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <8 x i16> [[A]], <8 x i16> [[B]], <8 x i32> <i32 4, i32 12, i32 5, i32 13, i32 6, i32 14, i32 7, i32 15>
-// CHECK-NEXT: ret <8 x i16> [[SHUFFLE_I]]
-//
-uint16x8_t test_vzip2q_u16(uint16x8_t a, uint16x8_t b) {
- return vzip2q_u16(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i32> @test_vzip2_u32(
-// CHECK-SAME: <2 x i32> noundef [[A:%.*]], <2 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i32> [[A]], <2 x i32> [[B]], <2 x i32> <i32 1, i32 3>
-// CHECK-NEXT: ret <2 x i32> [[SHUFFLE_I]]
-//
-uint32x2_t test_vzip2_u32(uint32x2_t a, uint32x2_t b) {
- return vzip2_u32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x i32> @test_vzip2q_u32(
-// CHECK-SAME: <4 x i32> noundef [[A:%.*]], <4 x i32> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x i32> [[A]], <4 x i32> [[B]], <4 x i32> <i32 2, i32 6, i32 3, i32 7>
-// CHECK-NEXT: ret <4 x i32> [[SHUFFLE_I]]
-//
-uint32x4_t test_vzip2q_u32(uint32x4_t a, uint32x4_t b) {
- return vzip2q_u32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x i64> @test_vzip2q_u64(
-// CHECK-SAME: <2 x i64> noundef [[A:%.*]], <2 x i64> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x i64> [[A]], <2 x i64> [[B]], <2 x i32> <i32 1, i32 3>
-// CHECK-NEXT: ret <2 x i64> [[SHUFFLE_I]]
-//
-uint64x2_t test_vzip2q_u64(uint64x2_t a, uint64x2_t b) {
- return vzip2q_u64(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x float> @test_vzip2_f32(
-// CHECK-SAME: <2 x float> noundef [[A:%.*]], <2 x float> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <2 x float> [[A]], <2 x float> [[B]], <2 x i32> <i32 1, i32 3>
-// CHECK-NEXT: ret <2 x float> [[SHUFFLE_I]]
-//
-float32x2_t test_vzip2_f32(float32x2_t a, float32x2_t b) {
- return vzip2_f32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <4 x float> @test_vzip2q_f32(
-// CHECK-SAME: <4 x float> noundef [[A:%.*]], <4 x float> noundef [[B:%.*]]) #[[ATTR0]] {
-// CHECK-NEXT: [[ENTRY:.*:]]
-// CHECK-NEXT: [[SHUFFLE_I:%.*]] = shufflevector <4 x float> [[A]], <4 x float> [[B]], <4 x i32> <i32 2, i32 6, i32 3, i32 7>
-// CHECK-NEXT: ret <4 x float> [[SHUFFLE_I]]
-//
-float32x4_t test_vzip2q_f32(float32x4_t a, float32x4_t b) {
- return vzip2q_f32(a, b);
-}
-
-// CHECK-LABEL: define dso_local <2 x double> @test_vzip2q_f64(
-// CHECK-SAME: <2 x double> noundef [[A:%.*]], <2 x double> noundef [[B:%.*]]) #[[ATT...
[truncated]
``````````
</details>
https://github.com/llvm/llvm-project/pull/194311
More information about the cfe-commits
mailing list