[arm][3/X] Implement __smla* intrinsics (Q-setting)
authorKyrylo Tkachov <kyrylo.tkachov@arm.com>
Thu, 7 Nov 2019 10:43:19 +0000 (10:43 +0000)
committerKyrylo Tkachov <ktkachov@gcc.gnu.org>
Thu, 7 Nov 2019 10:43:19 +0000 (10:43 +0000)
commit0883673194a2b28ad888498d74dac9a4cccc513c
treed0befb58d798bd19c32002a1bb137924a5dd4e3a
parente56d199b04fb7cde9b6ef423175883d852de78b4
[arm][3/X] Implement __smla* intrinsics (Q-setting)

This patch implements some more Q-setting intrinsics form the SMLA* group.
These can set the saturation bit on overflow in the accumulation step.
Like earlier, these have non-Q-setting RTL forms as well for when the
Q-bit read
is not needed.

* config/arm/arm.md (arm_smlabb_setq): New define_insn.
(arm_smlabb): New define_expand.
(*maddhisi4tb): Rename to...
(maddhisi4tb): ... This.
(*maddhisi4tt): Rename to...
(maddhisi4tt): ... This.
(arm_smlatb_setq): New define_insn.
(arm_smlatb): New define_expand.
(arm_smlatt_setq): New define_insn.
(arm_smlatt): New define_expand.
(arm_<smlaw_op><add_clobber_name>_insn): New define_insn.
(arm_<smlaw_op>): New define_expand.
* config/arm/arm_acle.h (__smlabb, __smlatb, __smlabt, __smlatt,
__smlawb, __smlawt): Define.
* config/arm_acle_builtins.def: Define builtins for the above.
* config/arm/iterators.md (SMLAWBT): New int_iterator.
(slaw_op): New int_attribute.
* config/arm/unspecs.md (UNSPEC_SMLAWB, UNSPEC_SMLAWT): Define.

* gcc.target/arm/acle/dsp_arith.c: Update test.

From-SVN: r277916
gcc/ChangeLog
gcc/config/arm/arm.md
gcc/config/arm/arm_acle.h
gcc/config/arm/arm_acle_builtins.def
gcc/config/arm/iterators.md
gcc/config/arm/unspecs.md
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/arm/acle/dsp_arith.c