z80:Opcodes:CPL

From Learn @ Cemetech
Revision as of 22:38, 5 February 2016 by Maintenance script (talk | contribs) (Initial automated import)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

CPL inverts all bits of A.

Syntax

   cpl

Effects

Sets H and N, other flags are unmodified.

Uses

This instruction returns the same value as XORing A with $FF or subtracting A from $FF. Also, CPL \ INC A returns the same value that NEG does.

T-States

4 t-states

See Also

NEG,XOR