linux-mips
[Top] [All Lists]

Re: [patch] Prevent dead code/data removal with gcc 3.4

To: Thiemo Seufer <ica2_ts@csv.ica.uni-stuttgart.de>
Subject: Re: [patch] Prevent dead code/data removal with gcc 3.4
From: Ralf Baechle <ralf@linux-mips.org>
Date: Sat, 14 Feb 2004 02:45:20 +0100
Cc: David Daney <ddaney@avtrex.com>, "Maciej W. Rozycki" <macro@ds2.pg.gda.pl>, linux-mips@linux-mips.org
In-reply-to: <20040214012801.GC20118@rembrandt.csv.ica.uni-stuttgart.de>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <Pine.LNX.4.55.0402131453360.15042@jurand.ds.pg.gda.pl> <20040213145316.GA23810@linux-mips.org> <20040213222253.GA20118@rembrandt.csv.ica.uni-stuttgart.de> <402D513F.8080205@avtrex.com> <20040213224959.GB20118@rembrandt.csv.ica.uni-stuttgart.de> <20040214011539.GB31847@linux-mips.org> <20040214012801.GC20118@rembrandt.csv.ica.uni-stuttgart.de>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Mutt/1.4.1i
On Sat, Feb 14, 2004 at 02:28:01AM +0100, Thiemo Seufer wrote:

> > It's the gcc generated function epilogue which is the problem.  There's
> > no reliable way to work around that ...
> 
> ITYM prologue. It has to follow the ABI specification, so $fp is the only
> possibly problematic one, and that's excluded by -fomit-frame-pointers.

Daniel Jacobowitz reported the problem which indeed was about $30.  Since
the kernel uses -fomit-frame-pointer by default (and -O1 enables it
by default on MIPS anyway) I would assume his kernel was built using that
option.  Maybe he can elaborate ...

Anyway, gcc could load next weeks lucky lottery numbers into the
s-registers after saving them.  That'd break save_static but not the
ABI which only promises to restore the old values in s-registers on
return.

  Ralf

<Prev in Thread] Current Thread [Next in Thread>