Has Anyone Written PDP-8 .XOR. Code Using the MQ Register (Without the EAE)?
Kyle Owen
kylevowen at gmail.com
Wed Dec 23 22:28:53 CST 2015
Here's the best I've got, Bob:
ARG1, 5252
ARG2, 2525
XOR, CLA
TAD ARG1 /~ARG1 & ARG2
CMA
AND ARG2
MQL /STORE IN MQ
TAD ARG2 /ARG1 & ~ARG2
CMA
AND ARG1
MQA /MQ OR AC -> AC
/RESULT IS 7777 IN AC
You can also add them and subtract two times the arguments ANDed together,
but I haven't played with that approach (yet). I did test the above code
with a few different values, and it seems to work just fine.
Kyle
More information about the cctalk
mailing list