6
The 68000's Instruction Set
two 128-bit numbers, each of which is stored as four consecutive
longwords.
LEA Number1,A0 A0 points at first number
LEA Number2,A1 A1 points at second number
MOVE #3,D0 Four longwords to add
MOVE #$00,CCR Clear X-bit and Z-bit of the CCR
LOOP ADDX -(A0),-(A1) Add pair of numbers
DBRA D0,LOOP Repeat until all added
Condition codes: X N Z V C
* * * * *
The Z-bit is cleared if the result is non-zero, and left unchanged
otherwise. The Z-bit can be used to test for zero after a chain of
multiple precision operations.
AND AND logical
Operation: [destination] ← [source].[destination]
Syntax: AND <ea>,Dn
AND Dn,<ea>
Attributes: Size = byte, word, longword
Description: AND the source operand to the destination operand and store
the result in the destination location.
Application: AND is used to mask bits. If we wish to clear bits 3 to 6 of data
register D7, we can execute AND #%10000111,D7. Unfortunately,
the AND operation cannot be used with an address register as
either a source or a destination operand. If you wish to perform a
logical operation on an address register, you have to copy the
address to a data register and then perform the operation there.
Condition codes: X N Z V C
- * * 0 0
Source operand addressing modes