[Bug target/53071] Wrong instruction replacement when compiling for xop

ubizjak at gmail dot com gcc-bugzilla@gcc.gnu.org
Fri Nov 23 07:51:00 GMT 2012


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53071

--- Comment #1 from Uros Bizjak <ubizjak at gmail dot com> 2012-11-23 07:49:41 UTC ---
Resulting asm is quite different w/ current mainline:

_Z4testU8__vectorxS_S_:
    vmovdqa    %xmm2, -24(%rsp)
    vpsrlq    $32, %xmm0, %xmm3
    vpmuldq    %xmm1, %xmm0, %xmm2
    vpmuldq    %xmm1, %xmm3, %xmm1
    vpand    .LC0(%rip), %xmm1, %xmm1
    vpsrlq    $32, %xmm2, %xmm2
    vmovd    -24(%rsp), %xmm4
    vpor    %xmm1, %xmm2, %xmm1
    vpaddd    %xmm0, %xmm1, %xmm1
    vpsrad    $31, %xmm0, %xmm0
    vpsrad    %xmm4, %xmm1, %xmm1
    vpsubd    %xmm0, %xmm1, %xmm0
    ret

_Z5test2U8__vectorxS_S_:
    vpxor    %xmm3, %xmm3, %xmm3
    vmovdqa    %xmm2, -24(%rsp)
    vpmuldq    %xmm1, %xmm0, %xmm2
    vpsrlq    $32, %xmm2, %xmm2
    vpmacsdqh    %xmm3, %xmm1, %xmm0, %xmm1
    vpand    .LC0(%rip), %xmm1, %xmm1
    vmovd    -24(%rsp), %xmm4
    vpor    %xmm1, %xmm2, %xmm1
    vpaddd    %xmm0, %xmm1, %xmm1
    vpsrad    $31, %xmm0, %xmm0
    vpsrad    %xmm4, %xmm1, %xmm1
    vpsubd    %xmm0, %xmm1, %xmm0
    ret



More information about the Gcc-bugs mailing list