News for hackers. Stuff that matters.
Re:XOR'ing a register with itself is the idiom for zeroing i... by rep_lodsb on Wednesday April 22, 2026 @11:31AM (#47865062)
Some other architectures like PDP-11 and 680x0 had a dedicated "clear register" instruction.

It could have been added to x86, even as a group of single-byte opcodes with the register encoded in three bits (as with PUSH, POP, and INC/DEC outside of long mode). But the XOR idiom was already established on the 8080 by that point.

There are no comments on this comment yet.