Re: [stella] Starmaster disassembled

Subject: Re: [stella] Starmaster disassembled
From: "Thomas Jentzsch" <tjentzsch@xxxxxx>
Date: Wed, 1 Aug 2001 09:08:15 +0200
Chris wrote:
>> BTW: Did someone else look at the code?
>> It seems that Alan Miller didn't know all opcodes of
>> the 650x well . He is always using CLC, ROR instead of
>> a simple LSR. Funny, isn't it?

> I haven't seen the code.  Is he using it for cycle counting?

No, it isn't used for cycle counting.


> Does he use the carry bit soon after?  

The state of the carry flag is changed by the ROL instruction, so the CLC doesn't help here.


> Not the best way to check bit 7
> (BNE, BEQ are better) but he might want to use the value of that bit
> in an ADC later...???

Actually he is checking bit 0 :) And LSR gives EXACTLY the same result as CLC, ROR (execept that it is 2 cylces faster)

I have to look at other code from him, to see if and when he learned to use LSR :)

Another interesting thing I found is, that the coding "style" (and quality) seems to differ. Some parts are very well done, and some other (especially some subroutines where he is encoding the state of 36 sectors into 18 bytes) are rather "suboptimal". 
This was not the first game for the 2600 Alan wrote, so maybe somebody else started or was involved into the project.

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


______________________________________________________________________________
Flug.de | Wer viel unterwegs ist, kann keine Zeit verschwenden   
http://flug.de/?PP=0-5-100-105-11


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

Current Thread