At 02:15 PM 5/29/2001 -0700, Hong Zhang wrote:
> > we have a simple set of load literal, push/pop (multiple) registers op
> > codes.
>
>There should be no push/pop opcodes. They are simply register moves.

The one handy thing about push and pop is you don't need to go tracking the 
stack manually--that's taken care of by the push and pop opcodes. They can 
certainly be replaced with manipulations of a temp register and indirect 
register stores or loads, but that's more expensive--you do the same thing 
only with more dispatch overhead.

And I'm considering the stack as a place to put registers temporarily when 
the compiler runs out and needs a spot to squirrel something away, rather 
than as a mechanism to pass parameters to subs or opcodes. This is a stack 
in the traditional scratch-space sense.

                                        Dan

--------------------------------------"it's like this"-------------------
Dan Sugalski                          even samurai
[EMAIL PROTECTED]                         have teddy bears and even
                                      teddy bears get drunk

Reply via email to