]> git.ipfire.org Git - thirdparty/gcc.git/commit
RISC-V: Add new option --param=gpr2vr-cost= for rvv insn
authorPan Li <pan2.li@intel.com>
Tue, 6 May 2025 08:26:06 +0000 (16:26 +0800)
committerPan Li <pan2.li@intel.com>
Tue, 6 May 2025 12:31:27 +0000 (20:31 +0800)
commit17c1602d5e7b237357b94808399a68ab77d42640
tree2d34983765b0d151a458f84ad81dc2c4ca69b177
parentac9fec014df8d75c2185981c9d191d1080e98094
RISC-V: Add new option --param=gpr2vr-cost= for rvv insn

During investigate the combine from vec_dup and vop.vv into
vop.vx, we need to depend on the cost of the insn operate
from the gpr to vr, for example, vadd.vx.  Thus, for better
control and test, we introduce a new option, aka below:

--param=gpr2vr-cost=<unsigned int>

To specific the cost value of the insn that operate from
the gpr to vr.

gcc/ChangeLog:

* config/riscv/riscv-opts.h (RVV_GR2VR_COST_UNPROVIDED): Add
new macro to indicate the param is not provided.
* config/riscv/riscv.opt: Add new option --pararm=gpr2vr-cost.

Signed-off-by: Pan Li <pan2.li@intel.com>
gcc/config/riscv/riscv-opts.h
gcc/config/riscv/riscv.opt