public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/56338] New: register spill caused by loading constant
@ 2013-02-15  7:41 neleai at seznam dot cz
  2013-02-15  7:42 ` [Bug other/56338] " neleai at seznam dot cz
  2013-02-15  7:59 ` [Bug target/56338] " pinskia at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: neleai at seznam dot cz @ 2013-02-15  7:41 UTC (permalink / raw)
  To: gcc-bugs


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

             Bug #: 56338
           Summary: register spill caused by loading constant
    Classification: Unclassified
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: other
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: neleai@seznam.cz


Consider attached code(smaller testcase has same bug but do not manifest by
spilling). 

gcc-4.7 -O3 spills rbp and rbx. 
  pushq %rbp
  .cfi_def_cfa_offset 16
  .cfi_offset 6, -16
  pxor  %xmm5, %xmm5
  movl  $63, %r10d
  movabsq $-9223372036854775808, %r11
  pushq %rbx
  .cfi_def_cfa_offset 24
  .cfi_offset 3, -24
  movl  $64, %ebx

Only use of rbx is this in loop below.: 
  movq  %rbx, %rdx

Same thing happens with 63 moved to r10d and used to initialize other register.


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

* [Bug other/56338] register spill caused by loading constant
  2013-02-15  7:41 [Bug other/56338] New: register spill caused by loading constant neleai at seznam dot cz
@ 2013-02-15  7:42 ` neleai at seznam dot cz
  2013-02-15  7:59 ` [Bug target/56338] " pinskia at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: neleai at seznam dot cz @ 2013-02-15  7:42 UTC (permalink / raw)
  To: gcc-bugs


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

--- Comment #1 from Ondrej Bilka <neleai at seznam dot cz> 2013-02-15 07:42:10 UTC ---
Created attachment 29461
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29461
testcase


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

* [Bug target/56338] register spill caused by loading constant
  2013-02-15  7:41 [Bug other/56338] New: register spill caused by loading constant neleai at seznam dot cz
  2013-02-15  7:42 ` [Bug other/56338] " neleai at seznam dot cz
@ 2013-02-15  7:59 ` pinskia at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: pinskia at gcc dot gnu.org @ 2013-02-15  7:59 UTC (permalink / raw)
  To: gcc-bugs


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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |missed-optimization, ra
             Target|                            |x86_64-linux-gnu
          Component|other                       |target

--- Comment #2 from Andrew Pinski <pinskia at gcc dot gnu.org> 2013-02-15 07:58:52 UTC ---
By the way I think you are violating C/C++ aliasing rules but that is a
different issue all together.


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

end of thread, other threads:[~2013-02-15  7:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-15  7:41 [Bug other/56338] New: register spill caused by loading constant neleai at seznam dot cz
2013-02-15  7:42 ` [Bug other/56338] " neleai at seznam dot cz
2013-02-15  7:59 ` [Bug target/56338] " pinskia at gcc dot gnu.org

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).