[Bug target/98167] [x86] Failure to optimize operation on indentically shuffled operands into a shuffle of the result of the operation

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Dec 7 12:43:21 GMT 2020


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98167

--- Comment #7 from Richard Biener <rguenth at gcc dot gnu.org> ---
The transform with doubles on the [1] element would produce

        unpckhpd        %xmm1, %xmm1
        unpckhpd        %xmm0, %xmm0
        mulsd   %xmm1, %xmm0
        unpcklpd        %xmm0, %xmm0

so that's not profitable.  Which vector element is cheap (free) to promote
to scalar possibly depends on the target (ppc/arm with BE lane order?).


More information about the Gcc-bugs mailing list