aboutsummaryrefslogtreecommitdiff
path: root/gcc/ggc-common.cc
diff options
context:
space:
mode:
authorLehua Ding <lehua.ding@rivai.ai>2023-09-13 13:07:40 +0800
committerLehua Ding <lehua.ding@rivai.ai>2023-09-14 22:54:30 +0800
commit14c481f7fc0a90de7e5b7aec109e12b7b5220d65 (patch)
treeaf7ea72aad87024e7d4f9c141d485a216b079f57 /gcc/ggc-common.cc
parentc8e4f0df685d7944257be5add25b5d60a074497f (diff)
downloadgcc-14c481f7fc0a90de7e5b7aec109e12b7b5220d65.zip
gcc-14c481f7fc0a90de7e5b7aec109e12b7b5220d65.tar.gz
gcc-14c481f7fc0a90de7e5b7aec109e12b7b5220d65.tar.bz2
RISC-V: Cleanup redundant reduction patterns after refactor vector mode
This patch cleanups redundant reduction patterns after Juzhe change vector mode from fixed-size to scalable-size. For example, whether it is zvl32b, zvl64b, zvl128b, RVVM1SI indicates that it occupies a vector register. Therefore, it is easy to map vector modes to LMUL1 vector modes with define_mode_attr without creating a separate pattern for each LMUL1 Mode. For example, this patch can combine four patterns (@pred_reduc_<reduc><VQI:mode><VQI_LMUL1:mode>, @pred_reduc_<reduc><VHI:mode><VHI_LMUL1:mode> @pred_reduc_<reduc><VSI:mode><VSI_LMUL1:mode>, @pred_reduc_<reduc><VDI:mode><VDI_LMUL1:mode>) to a single pattern @pred_reduc_<reduc><mode>. gcc/ChangeLog: * config/riscv/riscv-v.cc (expand_reduction): Adjust call. * config/riscv/riscv-vector-builtins-bases.cc: Adjust call. * config/riscv/vector-iterators.md: New iterators and attrs. * config/riscv/vector.md (@pred_reduc_<reduc><VQI:mode><VQI_LMUL1:mode>): Removed. (@pred_reduc_<reduc><VHI:mode><VHI_LMUL1:mode>): Removed. (@pred_reduc_<reduc><VSI:mode><VSI_LMUL1:mode>): Removed. (@pred_reduc_<reduc><VDI:mode><VDI_LMUL1:mode>): Removed. (@pred_reduc_<reduc><mode>): Added. (@pred_widen_reduc_plus<v_su><VQI:mode><VHI_LMUL1:mode>): Removed. (@pred_widen_reduc_plus<v_su><VHI:mode><VSI_LMUL1:mode>): Removed. (@pred_widen_reduc_plus<v_su><mode>): Added. (@pred_widen_reduc_plus<v_su><VSI:mode><VDI_LMUL1:mode>): Removed. (@pred_reduc_<reduc><VHF:mode><VHF_LMUL1:mode>): Removed. (@pred_reduc_<reduc><VSF:mode><VSF_LMUL1:mode>): Removed. (@pred_reduc_<reduc><VDF:mode><VDF_LMUL1:mode>): Removed. (@pred_reduc_plus<order><VHF:mode><VHF_LMUL1:mode>): Removed. (@pred_reduc_plus<order><VSF:mode><VSF_LMUL1:mode>): Removed. (@pred_reduc_plus<order><mode>): Added. (@pred_reduc_plus<order><VDF:mode><VDF_LMUL1:mode>): Removed. (@pred_widen_reduc_plus<order><VHF:mode><VSF_LMUL1:mode>): Removed. (@pred_widen_reduc_plus<order><VSF:mode><VDF_LMUL1:mode>): Removed. (@pred_widen_reduc_plus<order><mode>): Added.
Diffstat (limited to 'gcc/ggc-common.cc')
0 files changed, 0 insertions, 0 deletions