XOR'ing a register with itself is a common idiom for zeroing it out in programming.
Claims
XOR'ing a register with itself is a common idiom for zeroing it out in programming.
Parent: ProgrammingEntity: Register zeroing techniquesImpact: neutralDate: Apr 22, 2026Target: XOR'ing a register with itself is the idiom for zeroing it out.
Source posts
XOR'ing a register with itself is the idiom for zeroing it out. Why not sub?
https://devblogs.microsoft.com/oldnewthing/20260421-00/?p=112247
#HackerNews #XOR #zeroing #sub #register #programming #coding
0 boosts · 0 favs · 0 replies · Apr 22, 2026
#hackernews#xor#zeroing#sub#register#programming
XOR'ing a register with itself is the idiom for zeroing it out. Why not sub?
----
- 41 minutes ago | 4 points | 0 comments
- URL: https://devblogs.microsoft.com/oldnewthing/20260421-00/?p=112247
- Discussions: https://news.ycombinator.com/item?id=47859861
0 boosts · 0 favs · 0 replies · Apr 22, 2026
XOR'ing a register with itself is the idiom for zeroing it out. Why not sub?
L: https://devblogs.microsoft.com/oldnewthing/20260421-00/?p=112247
C: https://news.ycombinator.com/item?id=47859861
posted on 2026.04.22 at 02:38:05 (c=0, p=4)
0 boosts · 0 favs · 0 replies · Apr 22, 2026
XOR'ing a register with itself is the idiom for zeroing it out. Why not sub?
https://devblogs.microsoft.com/oldnewthing/20260421-00/?p=112247
#microsoft
0 boosts · 0 favs · 0 replies · Apr 22, 2026
#microsoft
XOR'ing a register with itself is the idiom for zeroing it out. Why not sub?
https://lemmy.bestiver.se/post/1063150
1 boosts · 0 favs · 0 replies · Apr 22, 2026
#hackernews
XOR'ing a register with itself is the idiom for zeroing it out. Why not sub?
Link: https://devblogs.microsoft.com/oldnewthing/20260421-00/?p=112247
Comments: https://news.ycombinator.com/item?id=47859861
0 boosts · 0 favs · 0 replies · Apr 22, 2026