XOR r

Operation

A <- A ^ r

Mnemonic

XOR

Operands

r

b7b6b5b4b3b2b1b0
1 0 1 0 1 r

Description

A logical exclusive-OR operation is performed between the contents of register r and the contents of the Accumulator. The result is stored in the Accumulator. The r symbol identifies the registers A, B, C, D, E, H, or L, assembled as follows in the object code:

RegisterrHex
A111$AF
B000$A8
C001$A9
D010$AA
E011$AB
H100$AC
L101$AD

Condition Bits Affected

Sis set if result is negative, otherwise it is reset.
Zis set if result is 0, otherwise it is reset.
His reset.
P/Vis set if parity even, otherwise it is reset
Nis reset.
Cis reset.

Example

If Register H contains $5D (0101 1101) and the Accumulator contains $96 (1001 0110), then upon the execution of

	XOR	H

the Accumulator contains $CB (1100 1011).