Re: [stella] Player data loading...semi newbie

Subject: Re: [stella] Player data loading...semi newbie
From: Thomas Jentzsch <tjentzsch@xxxxxx>
Date: Sat, 20 Oct 2001 15:03:33 +0100
Manuel Polik wrote:
> Wouldn't something like 'SLEEPCYCLES' X be more usefull, with X being a
> number in single cycle precission ranging from 2-n?
> DASM could automatically insert the best fitting mixture of 2 and 3
> cycle NOPs.

DASM already can do this! Just use it's features:

  MAC SLEEP
    IF {1} = 1
      ECHO "ERROR: SLEEP 1 not allowed !"
      END
    ENDIF
    IF {1} & 1
      nop $00          ; replace with bit to avoid illegal opcodes
      REPEAT ({1}-3)/2
        nop
      REPEND
    ELSE
      REPEAT {1}/2
        nop
      REPEND
    ENDIF
  ENDM

As you see, MAC and REPEAT can sometimes be quite useful :-)

Have fun!
Thomas                            
_______________________________________________________
Thomas Jentzsch         | *** Every bit is sacred ! ***
tjentzsch at web dot de |


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

Current Thread