Date : Fri, 12 Aug 1994 22:53:07 +0100 (BST)
From : clr1@...
Subject: Flags and BIT
I've got two quick questions for you guys; I wrote them down today when
trying to get my 6502 working (I've got 9% of the instruction set
implemented now; god knows if it works properly though!)
1. Are the flags set on the result of *every* operation? Even things like
LDA? And what about, for example, PHA? Just wondering. I've been setting
them on most instructions, just to be on the safe side.
2. Is the 6502 BIT instruction directly equivalent to the 80x86 TEST?
I discovered today that there was a rather major bug in my conditional
branches (I wasn't exactly sure why the O/S appeared to disappear into a
continuous loop all the time!). Oh, the trials of code development.
Just for interest - how long are you relevant source codes? Mine is
currently about 1800 lines; nearly 66Kb. Just wondering really. It's the
largest program I've written in my life (by about 5 times!).
+-------------------+-------------------------------------------------+
| /-- |_| /-- | (~ | "And the driving is like the driving of Jehu, |
| \-- | | | | _) | the son of Nimshi, for he drives furiously." |
+-------------------+-------------------- Second Book of Kings 9 v20 -+