diff --git a/llvm/lib/Target/AArch64/SVEInstrFormats.td b/llvm/lib/Target/AArch64/SVEInstrFormats.td --- a/llvm/lib/Target/AArch64/SVEInstrFormats.td +++ b/llvm/lib/Target/AArch64/SVEInstrFormats.td @@ -2270,6 +2270,8 @@ def : SVE_2_Op_Pat(NAME # _H)>; def : SVE_2_Op_Pat(NAME # _S)>; def : SVE_2_Op_Pat(NAME # _S)>; + def : SVE_2_Op_Pat(NAME # _D)>; + def : SVE_2_Op_Pat(NAME # _D)>; def : SVE_2_Op_Pat(NAME # _D)>; def : SVE_2_Op_Pat(NAME # _H)>; diff --git a/llvm/test/CodeGen/AArch64/sve-intrinsics-perm-select.ll b/llvm/test/CodeGen/AArch64/sve-intrinsics-perm-select.ll --- a/llvm/test/CodeGen/AArch64/sve-intrinsics-perm-select.ll +++ b/llvm/test/CodeGen/AArch64/sve-intrinsics-perm-select.ll @@ -1277,6 +1277,15 @@ ret %out } +define @trn1_f16_v2( %a, %b) { +; CHECK-LABEL: trn1_f16_v2: +; CHECK: trn1 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.trn1.nxv2f16( %a, + %b) + ret %out +} + define @trn1_f16_v4( %a, %b) { ; CHECK-LABEL: trn1_f16_v4: ; CHECK: trn1 z0.s, z0.s, z1.s @@ -1304,6 +1313,15 @@ ret %out } +define @trn1_f32_v2( %a, %b) { +; CHECK-LABEL: trn1_f32_v2: +; CHECK: trn1 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.trn1.nxv2f32( %a, + %b) + ret %out +} + define @trn1_f32( %a, %b) { ; CHECK-LABEL: trn1_f32: ; CHECK: trn1 z0.s, z0.s, z1.s @@ -1398,6 +1416,15 @@ ret %out } +define @trn2_f16_v2( %a, %b) { +; CHECK-LABEL: trn2_f16_v2: +; CHECK: trn2 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.trn2.nxv2f16( %a, + %b) + ret %out +} + define @trn2_f16_v4( %a, %b) { ; CHECK-LABEL: trn2_f16_v4: ; CHECK: trn2 z0.s, z0.s, z1.s @@ -1425,6 +1452,15 @@ ret %out } +define @trn2_f32_v2( %a, %b) { +; CHECK-LABEL: trn2_f32_v2: +; CHECK: trn2 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.trn2.nxv2f32( %a, + %b) + ret %out +} + define @trn2_f32( %a, %b) { ; CHECK-LABEL: trn2_f32: ; CHECK: trn2 z0.s, z0.s, z1.s @@ -1519,6 +1555,15 @@ ret %out } +define @uzp1_f16_v2( %a, %b) { +; CHECK-LABEL: uzp1_f16_v2: +; CHECK: uzp1 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.uzp1.nxv2f16( %a, + %b) + ret %out +} + define @uzp1_f16_v4( %a, %b) { ; CHECK-LABEL: uzp1_f16_v4: ; CHECK: uzp1 z0.s, z0.s, z1.s @@ -1546,6 +1591,15 @@ ret %out } +define @uzp1_f32_v2( %a, %b) { +; CHECK-LABEL: uzp1_f32_v2: +; CHECK: uzp1 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.uzp1.nxv2f32( %a, + %b) + ret %out +} + define @uzp1_f32( %a, %b) { ; CHECK-LABEL: uzp1_f32: ; CHECK: uzp1 z0.s, z0.s, z1.s @@ -1640,6 +1694,15 @@ ret %out } +define @uzp2_f16_v2( %a, %b) { +; CHECK-LABEL: uzp2_f16_v2: +; CHECK: uzp2 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.uzp2.nxv2f16( %a, + %b) + ret %out +} + define @uzp2_f16_v4( %a, %b) { ; CHECK-LABEL: uzp2_f16_v4: ; CHECK: uzp2 z0.s, z0.s, z1.s @@ -1667,6 +1730,15 @@ ret %out } +define @uzp2_f32_v2( %a, %b) { +; CHECK-LABEL: uzp2_f32_v2: +; CHECK: uzp2 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.uzp2.nxv2f32( %a, + %b) + ret %out +} + define @uzp2_f32( %a, %b) { ; CHECK-LABEL: uzp2_f32: ; CHECK: uzp2 z0.s, z0.s, z1.s @@ -1761,6 +1833,15 @@ ret %out } +define @zip1_f16_v2( %a, %b) { +; CHECK-LABEL: zip1_f16_v2: +; CHECK: zip1 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.zip1.nxv2f16( %a, + %b) + ret %out +} + define @zip1_f16_v4( %a, %b) { ; CHECK-LABEL: zip1_f16_v4: ; CHECK: zip1 z0.s, z0.s, z1.s @@ -1788,6 +1869,15 @@ ret %out } +define @zip1_f32_v2( %a, %b) { +; CHECK-LABEL: zip1_f32_v2: +; CHECK: zip1 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.zip1.nxv2f32( %a, + %b) + ret %out +} + define @zip1_f32( %a, %b) { ; CHECK-LABEL: zip1_f32: ; CHECK: zip1 z0.s, z0.s, z1.s @@ -1882,6 +1972,15 @@ ret %out } +define @zip2_f16_v2( %a, %b) { +; CHECK-LABEL: zip2_f16_v2: +; CHECK: zip2 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.zip2.nxv2f16( %a, + %b) + ret %out +} + define @zip2_f16_v4( %a, %b) { ; CHECK-LABEL: zip2_f16_v4: ; CHECK: zip2 z0.s, z0.s, z1.s @@ -1909,6 +2008,15 @@ ret %out } +define @zip2_f32_v2( %a, %b) { +; CHECK-LABEL: zip2_f32_v2: +; CHECK: zip2 z0.d, z0.d, z1.d +; CHECK-NEXT: ret + %out = call @llvm.aarch64.sve.zip2.nxv2f32( %a, + %b) + ret %out +} + define @zip2_f32( %a, %b) { ; CHECK-LABEL: zip2_f32: ; CHECK: zip2 z0.s, z0.s, z1.s @@ -2061,9 +2169,11 @@ declare @llvm.aarch64.sve.trn1.nxv8i16(, ) declare @llvm.aarch64.sve.trn1.nxv4i32(, ) declare @llvm.aarch64.sve.trn1.nxv2i64(, ) +declare @llvm.aarch64.sve.trn1.nxv2f16(, ) declare @llvm.aarch64.sve.trn1.nxv4f16(, ) declare @llvm.aarch64.sve.trn1.nxv8bf16(, ) declare @llvm.aarch64.sve.trn1.nxv8f16(, ) +declare @llvm.aarch64.sve.trn1.nxv2f32(, ) declare @llvm.aarch64.sve.trn1.nxv4f32(, ) declare @llvm.aarch64.sve.trn1.nxv2f64(, ) @@ -2075,9 +2185,11 @@ declare @llvm.aarch64.sve.trn2.nxv8i16(, ) declare @llvm.aarch64.sve.trn2.nxv4i32(, ) declare @llvm.aarch64.sve.trn2.nxv2i64(, ) +declare @llvm.aarch64.sve.trn2.nxv2f16(, ) declare @llvm.aarch64.sve.trn2.nxv4f16(, ) declare @llvm.aarch64.sve.trn2.nxv8bf16(, ) declare @llvm.aarch64.sve.trn2.nxv8f16(, ) +declare @llvm.aarch64.sve.trn2.nxv2f32(, ) declare @llvm.aarch64.sve.trn2.nxv4f32(, ) declare @llvm.aarch64.sve.trn2.nxv2f64(, ) @@ -2089,9 +2201,11 @@ declare @llvm.aarch64.sve.uzp1.nxv8i16(, ) declare @llvm.aarch64.sve.uzp1.nxv4i32(, ) declare @llvm.aarch64.sve.uzp1.nxv2i64(, ) +declare @llvm.aarch64.sve.uzp1.nxv2f16(, ) declare @llvm.aarch64.sve.uzp1.nxv4f16(, ) declare @llvm.aarch64.sve.uzp1.nxv8bf16(, ) declare @llvm.aarch64.sve.uzp1.nxv8f16(, ) +declare @llvm.aarch64.sve.uzp1.nxv2f32(, ) declare @llvm.aarch64.sve.uzp1.nxv4f32(, ) declare @llvm.aarch64.sve.uzp1.nxv2f64(, ) @@ -2103,9 +2217,11 @@ declare @llvm.aarch64.sve.uzp2.nxv8i16(, ) declare @llvm.aarch64.sve.uzp2.nxv4i32(, ) declare @llvm.aarch64.sve.uzp2.nxv2i64(, ) +declare @llvm.aarch64.sve.uzp2.nxv2f16(, ) declare @llvm.aarch64.sve.uzp2.nxv4f16(, ) declare @llvm.aarch64.sve.uzp2.nxv8bf16(, ) declare @llvm.aarch64.sve.uzp2.nxv8f16(, ) +declare @llvm.aarch64.sve.uzp2.nxv2f32(, ) declare @llvm.aarch64.sve.uzp2.nxv4f32(, ) declare @llvm.aarch64.sve.uzp2.nxv2f64(, ) @@ -2117,9 +2233,11 @@ declare @llvm.aarch64.sve.zip1.nxv8i16(, ) declare @llvm.aarch64.sve.zip1.nxv4i32(, ) declare @llvm.aarch64.sve.zip1.nxv2i64(, ) +declare @llvm.aarch64.sve.zip1.nxv2f16(, ) declare @llvm.aarch64.sve.zip1.nxv4f16(, ) declare @llvm.aarch64.sve.zip1.nxv8bf16(, ) declare @llvm.aarch64.sve.zip1.nxv8f16(, ) +declare @llvm.aarch64.sve.zip1.nxv2f32(, ) declare @llvm.aarch64.sve.zip1.nxv4f32(, ) declare @llvm.aarch64.sve.zip1.nxv2f64(, ) @@ -2131,9 +2249,11 @@ declare @llvm.aarch64.sve.zip2.nxv8i16(, ) declare @llvm.aarch64.sve.zip2.nxv4i32(, ) declare @llvm.aarch64.sve.zip2.nxv2i64(, ) +declare @llvm.aarch64.sve.zip2.nxv2f16(, ) declare @llvm.aarch64.sve.zip2.nxv4f16(, ) declare @llvm.aarch64.sve.zip2.nxv8bf16(, ) declare @llvm.aarch64.sve.zip2.nxv8f16(, ) +declare @llvm.aarch64.sve.zip2.nxv2f32(, ) declare @llvm.aarch64.sve.zip2.nxv4f32(, ) declare @llvm.aarch64.sve.zip2.nxv2f64(, )