Re: [stella] An exercise in minimalism...

Subject: Re: [stella] An exercise in minimalism...
From: "Andrew Davie" <adavie@xxxxxxxxxxxxxxxxx>
Date: Thu, 2 Sep 1999 14:32:54 +1000
I dug up my earlier posting regarding an efficient startup.
Here's my best...


    ; CLEARS ALL VARIABLES, STACK
    ; INIT STACK POINTER
    ; ALSO CLEARS TIA REGISTERS
    ; DOES THIS BY "WRAPPING" THE STACK - UNUSUAL

    LDX #0
    TXS
    PHA            ; BEST WAY TO GET SP=$FF, X=0

    TXA
CLEAR PHA
    DEX
    BNE CLEAR

    ; 9 BYTES TOTAL FOR CLEARING STACK, MEMORY
    ; STACK POINTER NOW $FF, A=X==0


Cheers
A


--
Archives (includes files) at http://www.biglist.com/lists/stella/archives/
Unsub & more at http://www.biglist.com/lists/stella/

Current Thread