[Coco] Assembly language question: The stack

Dave Philipsen dave at davebiz.com
Thu Oct 25 08:54:03 EDT 2018



> On Oct 25, 2018, at 6:58 AM, Luis Fernández <luis46coco at hotmail.com> wrote:
> 
> It is also possible to place a return to basic instruction, for example.
> 

So the mnemonic would be RTB?


> Since it is perfectly possible to use a PULS without having previously made a PSHS.
> 
> All this applies equally to the pointer U as well as to the pointer S
> 
> 
> 
> Enviado desde Correo<https://go.microsoft.com/fwlink/?LinkId=550986> para Windows 10
> 
> 
> 
> ________________________________
> De: Coco <coco-bounces at maltedmedia.com> en nombre de Ciaran Anscomb <cocomalt at 6809.org.uk>
> Enviado: Thursday, October 25, 2018 3:29:06 AM
> Para: CoCoList for Color Computer Enthusiasts
> Asunto: Re: [Coco] Assembly language question: The stack
> 
> Salvador Garcia via Coco wrote:
>> [stack works like ,-S ,S+]
>> I'll pause here in case any of the above needs correction.
> 
> Nope that's right.
> 
>> If I am correct in how the stack works, the first byte of the
>> stack is always wasted [...]
> 
> Not wasted, S doesn't have to point to usable RAM.  e.g., if ROM starts
> at $8000 and you want stack immediately below ROM, LDS #$8000 doesn't
> waste anything.
> 
>> Also, I assume it is the developer's responsibility to manage the stack,
> 
> Yep.
> 
> ..ciaran
> 
> --
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco
> 
> -- 
> Coco mailing list
> Coco at maltedmedia.com
> https://pairlist5.pair.net/mailman/listinfo/coco



More information about the Coco mailing list