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



--- Comment #13 from H.J. Lu <hjl.tools at gmail dot com> 2012-11-10 19:11:03 
UTC ---

(In reply to comment #12)

> (In reply to comment #11)

> > ~/gcc-build/gcc/cc1 -O2 -mx32 -maddress-mode=long pr55247.c

> > 

> > results in following sequence:

> > 

> >         movdqu  (%eax), %xmm0

> >         movdqa  %xmm0, (%rsp)

> >         movq    (%rsp), %rax

> >         movq    8(%rsp), %rdx

> >         movq    %rax, 16(%rsp)

> >         movq    %rdx, 24(%rsp)

> > 

> > while -maddress=mode=short produces expected code:

> > 

> >         movq    8(%eax), %rdx

> >         movq    (%eax), %rax

> >         movq    %rdx, 8(%esp)

> >         movq    %rax, (%esp)

> 

> This is related to PR 55259.  This patch:

> 

> http://gcc.gnu.org/ml/gcc-patches/2012-11/msg00799.html

> 

> fixes it.



With this fix, we don't need to change *movti_internal_rex64

since it generates redundant load/store.

Reply via email to