April 7, 2026
Grandpa chip hits the gym
DeiMOS – A Superoptimizer for the MOS 6502
Retro chip gets a robot coach; cheers, nitpicks, and old-school bragging rights
TLDR: DeiMOS is a tool that brute-forces ultra-efficient code for the old 6502 chip, something feasible because it only handles tiny 8-bit values. The crowd split fast: praise for the wizardry, nitpicks over cycle counts and undocumented tricks, and dreams of faster retro computers—proof that old silicon still sparks hot debates.
DeiMOS is a new “superoptimizer” for the 1975 MOS 6502 chip—the brain behind classics like the NES and Commodore 64—and the community is losing it. Instead of using guesswork like normal compilers, this tool brute-forces the shortest, fastest code. Because the 6502 is only 8-bit, it can actually test every input, making this retro magic workable in 2026.
But the headline act is the comments. The nostalgia crowd is swooning—one user called it “incredibly clever,” imagining old-school demo coders frantically checking their hand-tuned assembly against the machine’s picks. Then the min-maxers stormed in with stopwatch energy. One commenter flexed a faster, 7-byte alternative and side-eyed an example as “not very useful,” igniting the classic split: purists who avoid undocumented instructions vs pragmatists who’ll use any trick if it’s faster. Translation: is shaving cycles worth going off the official map?
Others are dreaming big. “This was impossible back then,” sighed a retro fan, already wishing for a snappier AppleSoft BASIC ROM. Meanwhile, link-sharers compared DeiMOS to similar code generators like pubby.games/codegen.html, calling this approach “more refined and useful.” The meme vibe? “Grandpa CPU just started CrossFit.” Bottom line: a 50-year-old chip just got a personal trainer, and the crowd’s split between cheering, coaching, and keeping score.
Key Points
- •DeiMOS is a superoptimizer that targets the MOS 6502, seeking optimal instruction sequences via exhaustive search.
- •Superoptimizers differ from compilers by searching all possible sequences rather than applying heuristic optimizations.
- •The 6502’s small, well-defined instruction set and limited features make it suitable for exhaustive superoptimization.
- •Correctness is verified by user-supplied state-generation and verification functions, testing up to 256 input cases for 8-bit data.
- •Performance optimizations include pruning sequences with undocumented/jamming opcodes, tracking deepest emulation point after branches, and avoiding generation of known-useless instructions.