diff options
author | Pan Li <pan2.li@intel.com> | 2023-11-02 18:40:10 +0800 |
---|---|---|
committer | Pan Li <pan2.li@intel.com> | 2023-11-03 11:35:23 +0800 |
commit | c3847ca0571e5ace2f1d6e3baed67fee13d9f93d (patch) | |
tree | b00bf7a02c07725556c0f7df0b768237e3e93fee /gcc/tree-vect-loop.cc | |
parent | 5ea3c039b784b0676323243940fd9916b1f6d540 (diff) | |
download | gcc-c3847ca0571e5ace2f1d6e3baed67fee13d9f93d.zip gcc-c3847ca0571e5ace2f1d6e3baed67fee13d9f93d.tar.gz gcc-c3847ca0571e5ace2f1d6e3baed67fee13d9f93d.tar.bz2 |
RISC-V: Refactor prefix [I/L/LL] rounding API autovec iterator
Update in v2:
* Add mode size equal check to disable different mode size when expand,
because the underlying codegen is not implemented yet.
Original log:
The previous rounding API start with i/l/ll only works on the same
mode types. For example as below, and we arrange the iterator similar
to fcvt.
* SF => SI
* DF => DI
After we refined this limination from middle-end, these API can also
vectorized with different type sizes, aka:
* HF => SI, HF => DI
* SF => DI, SF => SI
* DF => SI, DF => DI
Then the iterator cannot take care of this simply and this patch
would like to re-arrange the iterator in two items.
* V_VLS_F_CONVERT_SI: handle (HF, SF, DF) => SI
* V_VLS_F_CONVERT_DI: handle (HF, SF, DF) => DI
As well as related mode_attr to reconcile the new iterator.
gcc/ChangeLog:
* config/riscv/autovec.md (lrint<mode><v_i_l_ll_convert>2): Remove.
(lround<mode><v_i_l_ll_convert>2): Ditto.
(lceil<mode><v_i_l_ll_convert>2): Ditto.
(lfloor<mode><v_i_l_ll_convert>2): Ditto.
(lrint<mode><v_f2si_convert>2): New pattern for cvt from
FP to SI.
(lround<mode><v_f2si_convert>2): Ditto.
(lceil<mode><v_f2si_convert>2): Ditto.
(lfloor<mode><v_f2si_convert>2): Ditto.
(lrint<mode><v_f2di_convert>2): New pattern for cvt from
FP to DI.
(lround<mode><v_f2di_convert>2): Ditto.
(lceil<mode><v_f2di_convert>2): Ditto.
(lfloor<mode><v_f2di_convert>2): Ditto.
* config/riscv/vector-iterators.md: Renew iterators for both
the SI and DI.
Signed-off-by: Pan Li <pan2.li@intel.com>
Diffstat (limited to 'gcc/tree-vect-loop.cc')
0 files changed, 0 insertions, 0 deletions