public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/39442] In some cases __builtin_ia32_loadups generates a movaps instruction
       [not found] <bug-39442-4@http.gcc.gnu.org/bugzilla/>
@ 2021-08-08 20:00 ` pinskia at gcc dot gnu.org
  0 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-08-08 20:00 UTC (permalink / raw)
  To: gcc-bugs

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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
           Keywords|                            |wrong-code
      Known to fail|                            |4.1.2
      Known to work|                            |4.4.7, 4.5.3, 4.6.4, 4.7.1,
                   |                            |4.9.1, 6.1.0
         Resolution|---                         |FIXED
   Target Milestone|---                         |4.4.0

--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Fixed in GCC 4.4.0.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/39442] In some cases __builtin_ia32_loadups generates a movaps instruction
  2009-03-12 14:55 [Bug target/39442] New: " amanieu at gmail dot com
                   ` (3 preceding siblings ...)
  2009-03-12 15:54 ` pluto at agmk dot net
@ 2009-03-12 16:03 ` hjl dot tools at gmail dot com
  4 siblings, 0 replies; 6+ messages in thread
From: hjl dot tools at gmail dot com @ 2009-03-12 16:03 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from hjl dot tools at gmail dot com  2009-03-12 16:03 -------
(In reply to comment #4)
> (In reply to comment #3)
> 
> > >         call    get_arg
> > >         movups  (%rax), %xmm1
> > >         xorl    %edi, %edi
> > >         movaps  %xmm1, (%rsp)               [*]
> > 
> > We can use movaps since stack is aligned at 16byte here.
> > 
> > >         call    get_arg
> > >         movaps  (%rsp), %xmm1               [*]
> > 
> > Same here.
> 
> of course you can, but what for transfer xmm1=>(rsp)=>xmm1?
> 

xmm1 is a caller saved register. get_arg may change xmm1.


-- 


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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/39442] In some cases __builtin_ia32_loadups generates a movaps instruction
  2009-03-12 14:55 [Bug target/39442] New: " amanieu at gmail dot com
                   ` (2 preceding siblings ...)
  2009-03-12 15:47 ` hjl dot tools at gmail dot com
@ 2009-03-12 15:54 ` pluto at agmk dot net
  2009-03-12 16:03 ` hjl dot tools at gmail dot com
  4 siblings, 0 replies; 6+ messages in thread
From: pluto at agmk dot net @ 2009-03-12 15:54 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from pluto at agmk dot net  2009-03-12 15:53 -------
(In reply to comment #3)

> >         call    get_arg
> >         movups  (%rax), %xmm1
> >         xorl    %edi, %edi
> >         movaps  %xmm1, (%rsp)               [*]
> 
> We can use movaps since stack is aligned at 16byte here.
> 
> >         call    get_arg
> >         movaps  (%rsp), %xmm1               [*]
> 
> Same here.

of course you can, but what for transfer xmm1=>(rsp)=>xmm1?


-- 


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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/39442] In some cases __builtin_ia32_loadups generates a movaps instruction
  2009-03-12 14:55 [Bug target/39442] New: " amanieu at gmail dot com
  2009-03-12 15:06 ` [Bug target/39442] " hjl dot tools at gmail dot com
  2009-03-12 15:37 ` pluto at agmk dot net
@ 2009-03-12 15:47 ` hjl dot tools at gmail dot com
  2009-03-12 15:54 ` pluto at agmk dot net
  2009-03-12 16:03 ` hjl dot tools at gmail dot com
  4 siblings, 0 replies; 6+ messages in thread
From: hjl dot tools at gmail dot com @ 2009-03-12 15:47 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from hjl dot tools at gmail dot com  2009-03-12 15:47 -------
(In reply to comment #2)
> on x86_64/4.4.0 i see correct movups and weird aligned moves[*].
> 
> main:   subq    $24, %rsp
>         xorl    %edi, %edi
>         call    get_arg
>         movups  (%rax), %xmm1
>         xorl    %edi, %edi
>         movaps  %xmm1, (%rsp)               [*]

We can use movaps since stack is aligned at 16byte here.

>         call    get_arg
>         movaps  (%rsp), %xmm1               [*]

Same here.

>         movups  (%rax), %xmm0
>         call    sse_func
>         addq    $24, %rsp
>         ret
> 


-- 


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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/39442] In some cases __builtin_ia32_loadups generates a movaps instruction
  2009-03-12 14:55 [Bug target/39442] New: " amanieu at gmail dot com
  2009-03-12 15:06 ` [Bug target/39442] " hjl dot tools at gmail dot com
@ 2009-03-12 15:37 ` pluto at agmk dot net
  2009-03-12 15:47 ` hjl dot tools at gmail dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: pluto at agmk dot net @ 2009-03-12 15:37 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pluto at agmk dot net  2009-03-12 15:37 -------
on x86_64/4.4.0 i see correct movups and weird aligned moves[*].

main:   subq    $24, %rsp
        xorl    %edi, %edi
        call    get_arg
        movups  (%rax), %xmm1
        xorl    %edi, %edi
        movaps  %xmm1, (%rsp)               [*]
        call    get_arg
        movaps  (%rsp), %xmm1               [*]
        movups  (%rax), %xmm0
        call    sse_func
        addq    $24, %rsp
        ret


-- 

pluto at agmk dot net changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |pluto at agmk dot net


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


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug target/39442] In some cases __builtin_ia32_loadups generates a movaps instruction
  2009-03-12 14:55 [Bug target/39442] New: " amanieu at gmail dot com
@ 2009-03-12 15:06 ` hjl dot tools at gmail dot com
  2009-03-12 15:37 ` pluto at agmk dot net
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: hjl dot tools at gmail dot com @ 2009-03-12 15:06 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from hjl dot tools at gmail dot com  2009-03-12 15:06 -------
I believe this is fixed in gcc 4.4.0.


-- 

hjl dot tools at gmail dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |hjl dot tools at gmail dot
                   |                            |com


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


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-08-08 20:00 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <bug-39442-4@http.gcc.gnu.org/bugzilla/>
2021-08-08 20:00 ` [Bug target/39442] In some cases __builtin_ia32_loadups generates a movaps instruction pinskia at gcc dot gnu.org
2009-03-12 14:55 [Bug target/39442] New: " amanieu at gmail dot com
2009-03-12 15:06 ` [Bug target/39442] " hjl dot tools at gmail dot com
2009-03-12 15:37 ` pluto at agmk dot net
2009-03-12 15:47 ` hjl dot tools at gmail dot com
2009-03-12 15:54 ` pluto at agmk dot net
2009-03-12 16:03 ` hjl dot tools at gmail dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).