public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/33236]  New: -minimal-toc register should be psedu-register
@ 2007-08-29 18:34 pinskia at gcc dot gnu dot org
  2007-08-29 18:38 ` [Bug target/33236] " pinskia at gcc dot gnu dot org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-08-29 18:34 UTC (permalink / raw)
  To: gcc-bugs

If -minimal-toc is used with a leaf function (that uses global memory), the
register r31 is saved/restored which causes a LHS store on the Cell's PowerPC
side.
Simple example:
int i;
int f(void)
{
  return i;
}
asm:
        std 30,-16(1)
        ld 30,.LCTOC0@toc(2)
        ld 9,.LC0-.LCTOC1(30)
        lwz 3,0(9)
        ld 30,-16(1)  <--- LHS because this is most likely within 50 cycles
        blr


-- 
           Summary: -minimal-toc register should be psedu-register
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Keywords: missed-optimization
          Severity: enhancement
          Priority: P3
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: pinskia at gcc dot gnu dot org
GCC target triplet: powerpc64-linux-gnu


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


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

* [Bug target/33236] -minimal-toc register should be psedu-register
  2007-08-29 18:34 [Bug target/33236] New: -minimal-toc register should be psedu-register pinskia at gcc dot gnu dot org
@ 2007-08-29 18:38 ` pinskia at gcc dot gnu dot org
  2007-08-30 21:15 ` pinskia at gcc dot gnu dot org
  2008-01-03 17:46 ` [Bug target/33236] -mminimal-toc " pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-08-29 18:38 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2007-08-29 18:38 -------
s/r31/r30 in comment #0, r31 is the frame pointer :).


-- 


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


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

* [Bug target/33236] -minimal-toc register should be psedu-register
  2007-08-29 18:34 [Bug target/33236] New: -minimal-toc register should be psedu-register pinskia at gcc dot gnu dot org
  2007-08-29 18:38 ` [Bug target/33236] " pinskia at gcc dot gnu dot org
@ 2007-08-30 21:15 ` pinskia at gcc dot gnu dot org
  2008-01-03 17:46 ` [Bug target/33236] -mminimal-toc " pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-08-30 21:15 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pinskia at gcc dot gnu dot org  2007-08-30 21:15 -------
I have a patch which needs testing for the trunk.

I am thinking about adding to my normal testing -mminimal-toc with -m64.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |pinskia at gcc dot gnu dot
                   |dot org                     |org
             Status|UNCONFIRMED                 |ASSIGNED
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2007-08-30 21:15:01
               date|                            |


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


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

* [Bug target/33236] -mminimal-toc register should be psedu-register
  2007-08-29 18:34 [Bug target/33236] New: -minimal-toc register should be psedu-register pinskia at gcc dot gnu dot org
  2007-08-29 18:38 ` [Bug target/33236] " pinskia at gcc dot gnu dot org
  2007-08-30 21:15 ` pinskia at gcc dot gnu dot org
@ 2008-01-03 17:46 ` pinskia at gcc dot gnu dot org
  2 siblings, 0 replies; 4+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-01-03 17:46 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from pinskia at gcc dot gnu dot org  2008-01-03 17:41 -------
This is harder to do than I expected, the minimal toc register is used while
doing reload and using a psedu-register there causes reload to use a memory
location.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|pinskia at gcc dot gnu dot  |unassigned at gcc dot gnu
                   |org                         |dot org
             Status|ASSIGNED                    |NEW
            Summary|-minimal-toc register should|-mminimal-toc register
                   |be psedu-register           |should be psedu-register


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


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

end of thread, other threads:[~2008-01-03 17:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-08-29 18:34 [Bug target/33236] New: -minimal-toc register should be psedu-register pinskia at gcc dot gnu dot org
2007-08-29 18:38 ` [Bug target/33236] " pinskia at gcc dot gnu dot org
2007-08-30 21:15 ` pinskia at gcc dot gnu dot org
2008-01-03 17:46 ` [Bug target/33236] -mminimal-toc " pinskia at gcc dot gnu dot 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).