Port-sparc64 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Stack bias



>>> [Leaf routines] can instead use %fp for whatever they like, but
>>> need to leave %sp untouched.
>> The one that's shared with another stack frame can be scribbled on,
>> but the one that's not must not be?
> I'm pretty sure either you or me are confusing something, or a
> talking about a different window save state - just compile a leaf
> function with a reasonable modern gcc and it will do the optimization
> that probably both of us mean.

We clearly are talking about very different things.

I'm not entirely sure what you're talking about; my best guess is that
you're talking about not leaf routines but rather routines that don't
create their own stack frame, instead running entirely in %o*.  (In a
theoretical sense, such routines don't have to be leaf routines, but in
practice they pretty much do.)

I'm not talking about any "optimization" gcc could do; I'm talking
about whether routines that don't themselves need %sp (which among
other things pretty much compels them to be leaf routines) can use %o6
the way they can use %o0-%o5 and %o7.  It seemed to me you were saying
that they couldn't use %o6 but could use %i6, which struck me as so
utterly bizarre I felt sure there was something I was missing.  Whether
gcc, or any other compiler for that matter, is smart enough to do so is
a completely separate question.

/~\ The ASCII                             Mouse
\ / Ribbon Campaign
 X  Against HTML                mouse%rodents-montreal.org@localhost
/ \ Email!           7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B


Home | Main Index | Thread Index | Old Index