The sophisticated way to do nothing in assembly
Description
A classic 'Tuxedo Winnie the Pooh' meme format comparing two assembly language instructions. In the top panel, a regular, unimpressed Pooh is paired with the text 'nop'. This represents the standard, simple 'No Operation' instruction that tells a processor to do nothing for one clock cycle. In the bottom panel, a sophisticated Pooh in a tuxedo is paired with 'rjmp 0'. This represents 'Relative Jump 0', an instruction that tells the processor to jump to its own address, creating a deliberate, one-instruction infinite loop. The joke is a deep cut for low-level and embedded systems programmers, humorously framing the act of intentionally halting the CPU in an infinite loop as a more elegant and refined choice than simply skipping a single cycle
Comments
16Comment deleted
'nop' is asking the CPU to take a quick coffee break. 'rjmp 0' is telling it to stare into the abyss until the heat death of the universe, or until a watchdog timer mercifully bites
Why settle for a one-cycle nop when you can rjmp 0 and make the branch predictor, prefetch buffer, and power budget all share in the existential futility?
When you've been optimizing embedded systems for 20 years and realize your most elegant infinite loop is still just a fancy way to make the CPU do absolutely nothing while burning the exact same amount of power
Ah yes, the eternal debate: do you halt execution with elegant simplicity using NOP, or do you assert dominance by forcing the CPU into an infinite loop with RJMP 0? Real embedded engineers know that burning CPU cycles in style is far superior to merely doing nothing. Bonus points if you've actually debugged a production system where someone accidentally shipped the tuxedo version and wondered why the watchdog timer kept firing
Doing nothing is a nop; doing nothing with enterprise requirements is rjmp 0 - two cycles, survives linker relaxation, and doubles as a hot‑patch anchor when “nothing” inevitably gets a spec
Graduating from NOP to RJMP 0 is peak embedded: burn an extra cycle to make your bit‑banged bus pass timing, then call it instruction scheduling in the postmortem
NOP for honest idling; RJMP 0 for the architect's plausible deniability on that 'soft' reset
low level humor Comment deleted
Is this a mfking assembly reference? Comment deleted
This is a trap... A 0 can make you think that you're jumping to the same instruction, but if you check the docs (https://content.instructables.com/ORIG/FIH/E7GU/I301K81S/FIHE7GUI301K81S.pdf page 9, section 2.13) you can clearly see that 1 is always added to the address computation, so it jumps, indeed, to the next instruction Comment deleted
Well, if you jump to same instruction that’d be quite equal to hlt, but more like while (1) {}; So rjmp 0 is technically the same as nop - waste a cycle and move to the next instruction Comment deleted
exactly Comment deleted
That's exactly why it compared to nop in meme, but you explanation could be usefull for those who are not into the topic! Comment deleted
Lol Comment deleted
i'm too stupid for this meme😭 Comment deleted
relative jump to next inst = no operation Comment deleted