This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/33236] New: -minimal-toc register should be psedu-register
- From: "pinskia at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 29 Aug 2007 18:34:03 -0000
- Subject: [Bug target/33236] New: -minimal-toc register should be psedu-register
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
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