From: Craig Topper Date: Sat, 13 Aug 2016 06:48:41 +0000 (+0000) Subject: [AVX-512] Add isCommutable to scalar FMA3 instructions. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=eafdbecc44c48527d0a7d52b25ddedce7f7d85b4;p=platform%2Fupstream%2Fllvm.git [AVX-512] Add isCommutable to scalar FMA3 instructions. llvm-svn: 278596 --- diff --git a/llvm/lib/Target/X86/X86InstrAVX512.td b/llvm/lib/Target/X86/X86InstrAVX512.td index dc83c1b..06a8acf 100644 --- a/llvm/lib/Target/X86/X86InstrAVX512.td +++ b/llvm/lib/Target/X86/X86InstrAVX512.td @@ -5060,7 +5060,7 @@ multiclass avx512_fma3_132_round opc, string OpcodeStr, SDNode OpNode, defm rb: AVX512_maskable_3src, + (_.VT ( OpNode _.RC:$src1, _.RC:$src3, _.RC:$src2, (i32 imm:$rc))), 1, 1>, AVX512FMA3Base, EVEX_B, EVEX_RC; } @@ -5102,18 +5102,18 @@ multiclass avx512_fma3s_common opc, string OpcodeStr, X86VectorVTInfo _, dag RHS_r, dag RHS_m > { defm r_Int: AVX512_maskable_3src_scalar, AVX512FMA3Base; + "$src3, $src2", "$src2, $src3", RHS_VEC_r, 1, 1>, AVX512FMA3Base; defm m_Int: AVX512_maskable_3src_scalar, AVX512FMA3Base; + "$src3, $src2", "$src2, $src3", RHS_VEC_m, 1, 1>, AVX512FMA3Base; defm rb_Int: AVX512_maskable_3src_scalar, + OpcodeStr, "$rc, $src3, $src2", "$src2, $src3, $rc", RHS_VEC_rb, 1, 1>, AVX512FMA3Base, EVEX_B, EVEX_RC; - let isCodeGenOnly = 1 in { + let isCodeGenOnly = 1, isCommutable = 1 in { def r : AVX512FMA3