[clang] [llvm] [X86][AVX10.2] Support AVX10.2-SATCVT new instructions. (PR #101599)
Phoebe Wang via llvm-commits
llvm-commits at lists.llvm.org
Sun Aug 4 23:57:42 PDT 2024
================
@@ -821,6 +821,88 @@ def X86vpdpbuuds : SDNode<"X86ISD::VPDPBUUDS", SDTVnni>;
def X86Vmpsadbw : SDNode<"X86ISD::MPSADBW", SDTX86PSADBW>;
+def SDTAVX10SATCVT_BF162I : SDTypeProfile<1, 1, [
+ SDTCVecEltisVT<0, i16>, SDTCVecEltisVT<1, bf16>
+]>;
+
+def SDTAVX10SATCVT_PH2I : SDTypeProfile<1, 1, [
+ SDTCVecEltisVT<0, i16>, SDTCVecEltisVT<1, f16>
+]>;
+
+def SDTAVX10SATCVT_PS2I : SDTypeProfile<1, 1, [
+ SDTCVecEltisVT<0, i32>, SDTCVecEltisVT<1, f32>
+]>;
+
+def SDTAVX10SATCVT_PH2I_ROUND : SDTypeProfile<1, 2, [
+ SDTCVecEltisVT<0, i16>, SDTCVecEltisVT<1, f16>, SDTCisInt<2>
+]>;
+
+def SDTAVX10SATCVT_PS2I_RND : SDTypeProfile<1, 2, [
+ SDTCVecEltisVT<0, i32>, SDTCVecEltisVT<1, f32>, SDTCisInt<2>
+]>;
+
+def SDTAVX10SATCVT_PH2I_SAE : SDTypeProfile<1, 1, [
+ SDTCVecEltisVT<0, i16>, SDTCVecEltisVT<1, f16>,
+ SDTCisSameNumEltsAs<0, 1>
+]>;
+
+def SDTAVX10SATCVT_PS2I_SAE : SDTypeProfile<1, 1, [
+ SDTCVecEltisVT<0, i32>, SDTCVecEltisVT<1, f32>,
+ SDTCisSameNumEltsAs<0, 1>
+]>;
+
+def X86vcvtnebf162ibs
+ : SDNode<"X86ISD::VCVTNEBF162IBS", SDTAVX10SATCVT_BF162I>;
+
+def X86vcvtnebf162iubs
+ : SDNode<"X86ISD::VCVTNEBF162IUBS", SDTAVX10SATCVT_BF162I>;
+
+def X86vcvtph2ibs : SDNode<"X86ISD::VCVTPH2IBS", SDTAVX10SATCVT_PH2I>;
+
+def X86vcvtph2ibsRnd
+ : SDNode<"X86ISD::VCVTPH2IBS_RND", SDTAVX10SATCVT_PH2I_ROUND>;
+
+def X86vcvtph2iubs : SDNode<"X86ISD::VCVTPH2IUBS", SDTAVX10SATCVT_PH2I>;
+
+def X86vcvtph2iubsRnd
+ : SDNode<"X86ISD::VCVTPH2IUBS_RND", SDTAVX10SATCVT_PH2I_ROUND>;
+
+def X86vcvtps2ibs : SDNode<"X86ISD::VCVTPS2IBS", SDTAVX10SATCVT_PS2I>;
+
+def X86vcvtps2ibsRnd
+ : SDNode<"X86ISD::VCVTPS2IBS_RND", SDTAVX10SATCVT_PS2I_RND>;
+
+def X86vcvtps2iubs : SDNode<"X86ISD::VCVTPS2IUBS", SDTAVX10SATCVT_PS2I>;
+
+def X86vcvtps2iubsRnd
+ : SDNode<"X86ISD::VCVTPS2IUBS_RND", SDTAVX10SATCVT_PS2I_RND>;
----------------
phoebewang wrote:
Merge them to `X86vcvtf2i[u]bs` and `X86vcvtf2i[u]bsRnd`?
https://github.com/llvm/llvm-project/pull/101599
More information about the llvm-commits
mailing list