public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/48609] New: Inefficient complex float store
@ 2011-04-14 13:57 hjl.tools at gmail dot com
  2011-04-14 14:04 ` [Bug target/48609] Inefficient complex float load/store hjl.tools at gmail dot com
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: hjl.tools at gmail dot com @ 2011-04-14 13:57 UTC (permalink / raw)
  To: gcc-bugs

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

           Summary: Inefficient complex float store
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: hjl.tools@gmail.com
                CC: ubizjak@gmail.com
            Target: x86_64


[hjl@gnu-6 pr1000]$ cat s2.i
typedef _Complex float SCtype;
extern SCtype bar;
void
foo (SCtype x)
{
  bar = x;
}
[hjl@gnu-6 pr1000]$ /usr/gcc-4.7/bin/gcc -S -O2 s2.i   
[hjl@gnu-6 pr1000]$ cat s2.s
    .file    "s2.i"
    .text
    .p2align 4,,15
    .globl    foo
    .type    foo, @function
foo:
.LFB0:
    .cfi_startproc
    movq    %xmm0, -8(%rsp)
    movl    -8(%rsp), %eax
    movl    %eax, bar(%rip)
    movl    -4(%rsp), %eax
    movl    %eax, bar+4(%rip)
    ret
    .cfi_endproc
.LFE0:
    .size    foo, .-foo

We should simply do

movq    %xmm0, bar(%rip)


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

end of thread, other threads:[~2021-08-17 12:25 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-04-14 13:57 [Bug target/48609] New: Inefficient complex float store hjl.tools at gmail dot com
2011-04-14 14:04 ` [Bug target/48609] Inefficient complex float load/store hjl.tools at gmail dot com
2021-08-02 18:02 ` [Bug middle-end/48609] Inefficient complex float argument passing/return pinskia at gcc dot gnu.org
2021-08-02 18:06 ` pinskia at gcc dot gnu.org
2021-08-07  5:28 ` pinskia at gcc dot gnu.org
2021-08-17 10:35 ` crazylht at gmail dot com
2021-08-17 10:44 ` crazylht at gmail dot com
2021-08-17 10:55 ` pinskia at gcc dot gnu.org
2021-08-17 11:42 ` crazylht at gmail dot com
2021-08-17 12:25 ` crazylht 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).