https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114428
--- Comment #2 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by hongtao Liu <liuho...@gcc.gnu.org>: https://gcc.gnu.org/g:961dd0d635217c703a38c48903981e0d60962546 commit r15-1048-g961dd0d635217c703a38c48903981e0d60962546 Author: liuhongt <hongtao....@intel.com> Date: Fri Apr 19 10:39:53 2024 +0800 Adjust rtx_cost for MEM to enable more simplication For CONST_VECTOR_DUPLICATE_P in constant_pool, it is just broadcast or variants in ix86_vector_duplicate_simode_const. Adjust the cost to COSTS_N_INSNS (2) + speed which should be a little bit larger than broadcast. gcc/ChangeLog: PR target/114428 * config/i386/i386.cc (ix86_rtx_costs): Adjust cost for CONST_VECTOR_DUPLICATE_P in constant_pool. * config/i386/i386-expand.cc (ix86_broadcast_from_constant): Remove static. * config/i386/i386-protos.h (ix86_broadcast_from_constant): Declare. gcc/testsuite/ChangeLog: * gcc.target/i386/pr114428.c: New test.