[clang] [llvm] [X86][AVX10.2] Support AVX10.2-SATCVT-DS new instructions. (PR #102592)

Phoebe Wang via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 5 05:46:53 PDT 2024


================
@@ -625,6 +625,317 @@ defm VCVTTPS2IUBS : avx10_sat_cvt_base<0x6a, "vcvttps2iubs", SchedWriteVecIMul,
                                       X86vcvttp2iubsSAE>,
                     AVX512PDIi8Base, T_MAP5, EVEX_CD8<32, CD8VF>;
 
+//-------------------------------------------------
+// AVX10 SATCVT-DS instructions
+//-------------------------------------------------
+
+// Convert Double to Signed/Unsigned Doubleword with truncation.
+multiclass avx512_cvttpd2dqs<bits<8> opc, string OpcodeStr, SDPatternOperator OpNode,
+           SDNode MaskOpNode, SDNode OpNodeSAE,
+           X86SchedWriteWidths sched> {
+  let Predicates = [HasAVX10_2, HasAVX10_2_512] in {
+    defm Z : avx512_vcvt_fp<opc, OpcodeStr, v8i32x_info, v8f64_info, OpNode,
+                            MaskOpNode, sched.ZMM>,
+    avx512_vcvt_fp_sae<opc, OpcodeStr, v8i32x_info, v8f64_info,
+                       OpNodeSAE, sched.ZMM>, EVEX_V512;
+  }
+  let Predicates = [HasAVX10_2, HasVLX] in {
----------------
phoebewang wrote:

Use `HasAVX10_2` only. The same below.

https://github.com/llvm/llvm-project/pull/102592


More information about the cfe-commits mailing list