[Bug target/122065] powerpc64le: Vector multiplication optimizations for double word does not happen for power8/9
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Nov 8 03:17:57 GMT 2025
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122065
--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Avinash Jayakar <avinashd@gcc.gnu.org>:
https://gcc.gnu.org/g:bc62a2fbabad0402e96640b834d7c8a9f64c11db
commit r16-5095-gbc62a2fbabad0402e96640b834d7c8a9f64c11db
Author: Avinash Jayakar <avinashd@linux.ibm.com>
Date: Sat Nov 8 08:23:31 2025 +0530
vect: Complete implementation for MULT_EXPR vector lowering.
Use sequences of shifts and add/sub if the hardware does not have support
for
vector multiplication. In a previous patch, bare bones vector lowering had
been
implemented which only worked when the constant value was a power of 2.
In this patch, few more cases have been added, i.e., if a constant is a
uniform
vector but not a power of 2 then use the choose_mult_variant, with max cost
estimate as the cost of scalar multiplication operation times the number of
elements in the vector. This is similar to the logic while expanding
MULT_EXPR
in expand pass or in the vector pattern recognition in
tree-vect-patterns.cc.
2025-11-08 Avinash Jayakar <avinashd@linux.ibm.com>
gcc/ChangeLog:
PR tree-optimization/122065
* tree-vect-generic.cc (target_supports_mult_synth_alg): Add helper
to
check mult synth.
(expand_vector_mult): Optimize mult when const is uniform but not
power of 2.
More information about the Gcc-bugs
mailing list