+2019-10-26 Hongtao Liu <hongtao.liu@intel.com>
+
+ * config/i386/sse.md
+ (<sse>_vm<plusminus_insn><mode>3<mask_scalar_name><round_scalar_name>,
+ <sse>_vm<multdiv_mnemonic><mode>3<mask_scalar_name><round_scalar_name>,
+ <sse>_vmsqrt<mode>2<mask_scalar_name><round_scalar_name>,
+ <sse>_vm<code><mode>3<mask_scalar_name><round_saeonly_scalar_name>,
+ <sse>_vmmaskcmp<mode>3):
+ Change predicates from vector_operand to nonimmediate_operand,
+ constraints xBm to xm, since scalar operations don't need
+ memory address alignment.
+ (avx512f_vmcmp<mode>3<round_saeonly_name>,
+ avx512f_vmcmp<mode>3_mask<round_saeonly_name>): Replace
+ round_saeonly_nimm_predicate with
+ round_saeonly_nimm_scalar_predicate.
+ (fmai_vmfmadd_<mode><round_name>, fmai_vmfmsub_<mode><round_name>,
+ fmai_vmfnmadd_<mode><round_name>,fmai_vmfnmsub_<mode><round_name>,
+ *fmai_fmadd_<mode>, *fmai_fmsub_<mode>,
+ *fmai_fnmadd_<mode><round_name>, *fmai_fnmsub_<mode><round_name>,
+ avx512f_vmfmadd_<mode>_mask3<round_name>,
+ avx512f_vmfmadd_<mode>_maskz_1<round_name>,
+ *avx512f_vmfmsub_<mode>_mask<round_name>,
+ avx512f_vmfmsub_<mode>_mask3<round_name>,
+ *avx512f_vmfmsub_<mode>_maskz_1<round_name>,
+ *avx512f_vmfnmadd_<mode>_mask<round_name>,
+ *avx512f_vmfnmadd_<mode>_mask3<round_name>,
+ *avx512f_vmfnmadd_<mode>_maskz_1<round_name>,
+ *avx512f_vmfnmsub_<mode>_mask<round_name>,
+ *avx512f_vmfnmsub_<mode>_mask3<round_name>,
+ *avx512f_vmfnmsub_<mode>_maskz_1<round_name>,
+ cvtusi2<ssescalarmodesuffix>32<round_name>,
+ cvtusi2<ssescalarmodesuffix>64<round_name>, ): Replace
+ round_nimm_predicate with round_nimm_scalr_predicate.
+ (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
+ avx512f_sfixupimm<mode>_mask<round_saeonly_name>,
+ avx512er_vmrcp28<mode><round_saeonly_name>,
+ avx512er_vmrsqrt28<mode><round_saeonly_name>,
+ ): Replace round_saeonly_nimm_predicate with
+ round_saeonly_nimm_scalar_predicate.
+ (avx512dq_vmfpclass<mode><mask_scalar_merge_name>): Replace
+ vector_operand with nonimmediate_operand.
+ * config/i386/subst.md (round_scalar_nimm_predicate,
+ round_saeonly_scalar_nimm_predicate): Replace
+ vector_operand with nonimmediate_operand.
+
2019-10-26 Hongtao Liu <hongtao.liu@intel.com>
PR target/89071
(vec_merge:VF_128
(plusminus:VF_128
(match_operand:VF_128 1 "register_operand" "0,v")
- (match_operand:VF_128 2 "vector_operand" "xBm,<round_scalar_constraint>"))
+ (match_operand:VF_128 2 "nonimmediate_operand" "xm,<round_scalar_constraint>"))
(match_dup 1)
(const_int 1)))]
"TARGET_SSE"
(vec_merge:VF_128
(multdiv:VF_128
(match_operand:VF_128 1 "register_operand" "0,v")
- (match_operand:VF_128 2 "vector_operand" "xBm,<round_scalar_constraint>"))
+ (match_operand:VF_128 2 "nonimmediate_operand" "xm,<round_scalar_constraint>"))
(match_dup 1)
(const_int 1)))]
"TARGET_SSE"
[(set (match_operand:VF_128 0 "register_operand" "=x,v")
(vec_merge:VF_128
(sqrt:VF_128
- (match_operand:VF_128 1 "vector_operand" "xBm,<round_scalar_constraint>"))
+ (match_operand:VF_128 1 "nonimmediate_operand" "xm,<round_scalar_constraint>"))
(match_operand:VF_128 2 "register_operand" "0,v")
(const_int 1)))]
"TARGET_SSE"
(vec_merge:VF_128
(smaxmin:VF_128
(match_operand:VF_128 1 "register_operand" "0,v")
- (match_operand:VF_128 2 "vector_operand" "xBm,<round_saeonly_scalar_constraint>"))
+ (match_operand:VF_128 2 "nonimmediate_operand" "xm,<round_saeonly_scalar_constraint>"))
(match_dup 1)
(const_int 1)))]
"TARGET_SSE"
(vec_merge:VF_128
(match_operator:VF_128 3 "sse_comparison_operator"
[(match_operand:VF_128 1 "register_operand" "0,x")
- (match_operand:VF_128 2 "vector_operand" "xBm,xm")])
+ (match_operand:VF_128 2 "nonimmediate_operand" "xm,xm")])
(match_dup 1)
(const_int 1)))]
"TARGET_SSE"
(and:<avx512fmaskmode>
(unspec:<avx512fmaskmode>
[(match_operand:VF_128 1 "register_operand" "v")
- (match_operand:VF_128 2 "<round_saeonly_nimm_predicate>" "<round_saeonly_constraint>")
+ (match_operand:VF_128 2 "<round_saeonly_nimm_scalar_predicate>" "<round_saeonly_constraint>")
(match_operand:SI 3 "const_0_to_31_operand" "n")]
UNSPEC_PCMP)
(const_int 1)))]
(and:<avx512fmaskmode>
(unspec:<avx512fmaskmode>
[(match_operand:VF_128 1 "register_operand" "v")
- (match_operand:VF_128 2 "<round_saeonly_nimm_predicate>" "<round_saeonly_constraint>")
+ (match_operand:VF_128 2 "<round_saeonly_nimm_scalar_predicate>" "<round_saeonly_constraint>")
(match_operand:SI 3 "const_0_to_31_operand" "n")]
UNSPEC_PCMP)
(and:<avx512fmaskmode>
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand")
- (match_operand:VF_128 2 "<round_nimm_predicate>")
- (match_operand:VF_128 3 "<round_nimm_predicate>"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>")
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>"))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA")
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand")
- (match_operand:VF_128 2 "<round_nimm_predicate>")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>")))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA")
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>"))
(match_operand:VF_128 1 "register_operand")
- (match_operand:VF_128 3 "<round_nimm_predicate>"))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>"))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA")
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>"))
(match_operand:VF_128 1 "register_operand")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>")))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA")
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>, v")
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>, v")
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>"))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA || TARGET_AVX512F"
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>")))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA || TARGET_AVX512F"
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v"))
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>"))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>"))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA || TARGET_AVX512F"
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v"))
(match_operand:VF_128 1 "register_operand" "0,0")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>")))
(match_dup 1)
(const_int 1)))]
"TARGET_FMA || TARGET_AVX512F"
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v")
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v")
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>"))
(match_dup 1)
(match_operand:QI 4 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(vec_merge:VF_128
(fma:VF_128
- (match_operand:VF_128 1 "<round_nimm_predicate>" "%v")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>")
+ (match_operand:VF_128 1 "<round_nimm_scalar_predicate>" "%v")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>")
(match_operand:VF_128 3 "register_operand" "0"))
(match_dup 3)
(match_operand:QI 4 "register_operand" "Yk"))
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v")
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v")
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>"))
(match_operand:VF_128 4 "const0_operand" "C,C")
(match_operand:QI 5 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>")))
(match_dup 1)
(match_operand:QI 4 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(vec_merge:VF_128
(fma:VF_128
- (match_operand:VF_128 1 "<round_nimm_predicate>" "%v")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>")
+ (match_operand:VF_128 1 "<round_nimm_scalar_predicate>" "%v")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>")
(neg:VF_128
(match_operand:VF_128 3 "register_operand" "0")))
(match_dup 3)
(vec_merge:VF_128
(fma:VF_128
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>")))
(match_operand:VF_128 4 "const0_operand" "C,C")
(match_operand:QI 5 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v"))
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>"))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>"))
(match_dup 1)
(match_operand:QI 4 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>"))
- (match_operand:VF_128 1 "<round_nimm_predicate>" "%v")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>"))
+ (match_operand:VF_128 1 "<round_nimm_scalar_predicate>" "%v")
(match_operand:VF_128 3 "register_operand" "0"))
(match_dup 3)
(match_operand:QI 4 "register_operand" "Yk"))
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v"))
(match_operand:VF_128 1 "register_operand" "0,0")
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>"))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>"))
(match_operand:VF_128 4 "const0_operand" "C,C")
(match_operand:QI 5 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v"))
(match_operand:VF_128 1 "register_operand" "0,0")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>")))
(match_dup 1)
(match_operand:QI 4 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>"))
- (match_operand:VF_128 1 "<round_nimm_predicate>" "%v")
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>"))
+ (match_operand:VF_128 1 "<round_nimm_scalar_predicate>" "%v")
(neg:VF_128
(match_operand:VF_128 3 "register_operand" "0")))
(match_dup 3)
(vec_merge:VF_128
(fma:VF_128
(neg:VF_128
- (match_operand:VF_128 2 "<round_nimm_predicate>" "<round_constraint>,v"))
+ (match_operand:VF_128 2 "<round_nimm_scalar_predicate>" "<round_constraint>,v"))
(match_operand:VF_128 1 "register_operand" "0,0")
(neg:VF_128
- (match_operand:VF_128 3 "<round_nimm_predicate>" "v,<round_constraint>")))
+ (match_operand:VF_128 3 "<round_nimm_scalar_predicate>" "v,<round_constraint>")))
(match_operand:VF_128 4 "const0_operand" "C,C")
(match_operand:QI 5 "register_operand" "Yk,Yk"))
(match_dup 1)
(vec_merge:VF_128
(vec_duplicate:VF_128
(unsigned_float:<ssescalarmode>
- (match_operand:SI 2 "<round_nimm_predicate>" "<round_constraint3>")))
+ (match_operand:SI 2 "<round_nimm_scalar_predicate>" "<round_constraint3>")))
(match_operand:VF_128 1 "register_operand" "v")
(const_int 1)))]
"TARGET_AVX512F && <round_modev4sf_condition>"
(vec_merge:VF_128
(vec_duplicate:VF_128
(unsigned_float:<ssescalarmode>
- (match_operand:DI 2 "<round_nimm_predicate>" "<round_constraint3>")))
+ (match_operand:DI 2 "<round_nimm_scalar_predicate>" "<round_constraint3>")))
(match_operand:VF_128 1 "register_operand" "v")
(const_int 1)))]
"TARGET_AVX512F && TARGET_64BIT"
(unspec:VF_128
[(match_operand:VF_128 1 "register_operand" "0")
(match_operand:VF_128 2 "register_operand" "v")
- (match_operand:<sseintvecmode> 3 "<round_saeonly_nimm_predicate>" "<round_saeonly_constraint>")
+ (match_operand:<sseintvecmode> 3 "<round_saeonly_nimm_scalar_predicate>" "<round_saeonly_constraint>")
(match_operand:SI 4 "const_0_to_255_operand")]
UNSPEC_FIXUPIMM)
(match_dup 1)
(unspec:VF_128
[(match_operand:VF_128 1 "register_operand" "0")
(match_operand:VF_128 2 "register_operand" "v")
- (match_operand:<sseintvecmode> 3 "<round_saeonly_nimm_predicate>" "<round_saeonly_constraint>")
+ (match_operand:<sseintvecmode> 3 "<round_saeonly_nimm_scalar_predicate>" "<round_saeonly_constraint>")
(match_operand:SI 4 "const_0_to_255_operand")]
UNSPEC_FIXUPIMM)
(match_dup 1)
[(set (match_operand:VF_128 0 "register_operand" "=v")
(vec_merge:VF_128
(unspec:VF_128
- [(match_operand:VF_128 1 "<round_saeonly_nimm_predicate>" "<round_saeonly_constraint>")]
+ [(match_operand:VF_128 1 "<round_saeonly_nimm_scalar_predicate>" "<round_saeonly_constraint>")]
UNSPEC_RCP28)
(match_operand:VF_128 2 "register_operand" "v")
(const_int 1)))]
[(set (match_operand:VF_128 0 "register_operand" "=v")
(vec_merge:VF_128
(unspec:VF_128
- [(match_operand:VF_128 1 "<round_saeonly_nimm_predicate>" "<round_saeonly_constraint>")]
+ [(match_operand:VF_128 1 "<round_saeonly_nimm_scalar_predicate>" "<round_saeonly_constraint>")]
UNSPEC_RSQRT28)
(match_operand:VF_128 2 "register_operand" "v")
(const_int 1)))]
[(set (match_operand:<avx512fmaskmode> 0 "register_operand" "=k")
(and:<avx512fmaskmode>
(unspec:<avx512fmaskmode>
- [(match_operand:VF_128 1 "vector_operand" "vm")
+ [(match_operand:VF_128 1 "nonimmediate_operand" "vm")
(match_operand:QI 2 "const_0_to_255_operand" "n")]
UNSPEC_FPCLASS)
(const_int 1)))]