Subject: [stella] BIT and... AND From: Piero Cavina <p.cavina@xxxxxxxxxxxxx> Date: Tue, 22 Jul 1997 10:55:29 +0200 (MET DST) |
I was going to spend some time cleaning and optimizing my code, when I realized that I hadn't used the BIT instruction (I haven't a complete 6502 reference...) I remember that it can be used to test bit 7 and 6 without touching the accumulator content (this can be useful), and that it sets the zero flag according to the result of the logical AND between the accumulator and the memory. This last thing is less clear to me, I mean are these things the same...: LDA #mask BIT memory BEQ ... (BNE ...) or LDA memory AND #mask BEQ ... (BNE ...) How should I choose between the two solutions? Ciao, P. -- Archives updated once/day at http://www.biglist.com/lists/stella/archives/ Unsubscribing and other info at http://www.biglist.com/lists/stella/stella.html
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [stella] Frame Timed Sound Effe, Eckhard Stolberg | Thread | Re: [stella] BIT and... AND, Eckhard Stolberg |
Re: [stella] Frame Timed Sound Effe, Eckhard Stolberg | Date | Re: [stella] BIT and... AND, Eckhard Stolberg |
Month |