mips: omit initialization of $gp and stack allocation when possible
Alexandre Oliva
aoliva@redhat.com
Wed May 7 19:32:00 GMT 2003
On Apr 1, 2003, Alexandre Oliva <aoliva@redhat.com> wrote:
> On Mar 24, 2003, Alexandre Oliva <aoliva@redhat.com> wrote:
>> This patch improves the code generated by GCC on mips for functions
>> that don't need $gp to be set. It also documents a number of things
>> that formerly went unexplained about stack allocation and $gp slot
>> assignment, and cleans up some gunk that had piled up with the
>> confusion of ABIs in the mips back-end. This was tested on
>> mips64-linux-gnu and mips-sgi-irix6.5.
> There was a bug in the patch, that might cause it to recover the stack
> space reserved for $gp even when no such space was allocated, causing
> the frame size to potentially go negative. Oops. Thanks to Richard
> Sandiford for spotting it. This revised patch fixes it. It was
> tested on mips64-linux-gnu (also building a 32-bit kernel, which
> happened to trigger the bug) and mips-sgi-irix6.5. Ok to install?
This is an updated version of the patch, such that it applies cleanly
after the merged from mips-rewrite-branch. No changes other than
patch context. Tested by bootstrapping on mips-sgi-irix6.5 with
native as and ld, and mips-sgi-irix6.5o32 with GNU as (for some reason
the native as didn't seem to like some %got expressions introduced
with the rewrite when assembling for -32).
Ok to install?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mips-skip-gp-setup.patch
Type: text/x-patch
Size: 20967 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20030507/600cc2ab/attachment.bin>
-------------- next part --------------
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{redhat.com, gcc.gnu.org}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist Professional serial bug killer
More information about the Gcc-patches
mailing list