This is the mail archive of the
mailing list for the GCC project.
Re: Don't lose asm sets of frame pointer
On Mon, Nov 24, 2003 at 04:33:33PM +0100, Falk Hueffner wrote:
> does gcc now error out if
> you try to clobber the FP in an asm, but gcc needs it?
No. The patch doesn't do anything about detecting use of FP in asms
when gcc needs it as a frame pointer.
The patch is really aimed at the case where FP (and the pic register on
PPC) is free to use as a general register. Reasonably savvy users can
look at generated assembly for a function and decide that it should be
possible to use FP in asms. It's difficult enough to explain away gcc's
behaviour in these cases, but it's even more difficult to explain and
plain annoying that the pic register (r30) on PPC can't be used safely
Incidentally, the testcase originally came from Oracle, who apparently
hit the r30 problem in real code.
IBM OzLabs - Linux Technology Centre