This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: GCC bug on PowerPC with gcc 2.95.2?



Cort Dougan <cort@fsmlabs.com> writes:

> In the inline asm I change r1 but I tell gcc in the 'modifies' constraint
> that I've changed it.  The output asm shows that it doesn't save/restore r1
> during that code, though.

r1 is the stack pointer.  GCC assumes that if you change it, you meant
it to be changed.

Even if GCC saved it, it would save it on the stack, and of course
then there'd be no way to restore it.

-- 
- Geoffrey Keating <geoffk@geoffk.org>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]