MIPS PATCH: profiling fixes

Sandra Loosemore sandra@codesourcery.com
Sun Sep 9 04:31:00 GMT 2007


Daniel Jacobowitz wrote:
> 
> Have you tried this on mips-linux, or any other non-bare-metal MIPS
> configurations?  I think it'll break them.  GNU libc's _mcount
> restores $ra when it is finished, based on the value in $at when
> it was entered.  There may be other similar versions of _mcount
> around.  I don't know where the convention comes from; probably
> IRIX.

Hrmmm, no, I didn't try that.  I can conditionalize this for SDE's 
_mcount, but I don't think saving an extra register in the stack frame 
would actually break anything, even if it's not necessary for the Linux 
implementation of _mcount.  Anyway, I'll see if I can figure out how to 
test this in a Linux build.  :-P

> The NO_PROFILE_COUNTERS patch seems to be redundant.  It's already
> defined in mips.h.

Ooops, yes, you're right about that.  Maybe I need to start wearing my 
glasses while hacking again.  ;-)

-Sandra the nearsighted



More information about the Gcc-patches mailing list