Re: [PATCH] RISC-V: Add pattern for vector-scalar floating-point max

2025-09-03 Thread Jeff Law
On 9/2/25 11:01 AM, Paul-Antoine Arras wrote: On 02/09/2025 16:16, Jeff Law wrote: On 9/1/25 5:07 AM, Paul-Antoine Arras wrote: This pattern enables the combine pass (or late-combine, depending on the case) to merge a vec_duplicate into an smax RTL instruction. [ ... ] diff --git gcc/c

Re: [PATCH] RISC-V: Add pattern for vector-scalar floating-point max

2025-09-03 Thread Jeff Law
On 9/1/25 5:07 AM, Paul-Antoine Arras wrote: This pattern enables the combine pass (or late-combine, depending on the case) to merge a vec_duplicate into an smax RTL instruction. [ ... ] diff --git gcc/config/riscv/autovec-opt.md gcc/config/riscv/autovec-opt.md index 9695fdcb5c9..d56fb5f2

Re: [PATCH] RISC-V: Add pattern for vector-scalar floating-point max

2025-09-02 Thread Paul-Antoine Arras
On 02/09/2025 16:16, Jeff Law wrote: On 9/1/25 5:07 AM, Paul-Antoine Arras wrote: This pattern enables the combine pass (or late-combine, depending on the case) to merge a vec_duplicate into an smax RTL instruction. [ ... ] diff --git gcc/config/riscv/autovec-opt.md gcc/config/riscv/autove

[PATCH] RISC-V: Add pattern for vector-scalar floating-point max

2025-09-01 Thread Paul-Antoine Arras
This pattern enables the combine pass (or late-combine, depending on the case) to merge a vec_duplicate into an smax RTL instruction. Before this patch, we have two instructions, e.g.: vfmv.v.f v2,fa0 vfmax.vv v1,v1,v2 After, we get only one: vfmax.vf v1,v1,fa0 In some ca