[A83] Re: push - pop


[Prev][Next][Index][Thread]

[A83] Re: push - pop




> Van: Patrick Davidson <pad@OCF.Berkeley.EDU>
> 
> > Now what the hell happens??
> > I don't get it that only one sp can hold the answer to
> > multiple register pairs being pushed/popped.
> > Maybe every regiter pair has (inside the opcode of push/pop)
> > an offset, I mean the stack is divided into a piece
> > for bc, one for hl, one for de and one for af.
> 
> If you ever read any tutorial which suggests ideas like that, I would
> recommend you burn every copy of that tutorial that you have.

It's not that there are any tutorials that explicitly say so, it's just
that they always use it that way.

Something like this:

push	bc
[..code..]
pop	bc

Never anything difficult with push/popping inside a loop or whatever.

	Henk Poley <><