The time the Windows x86 emulator team found code so bad that they fixed it during emulation
Another story from the good old days from Raymond Chen.
During an exchange of war stories, a colleague of mine told one from back in the days when Windows included a processor emulator for x86-32 on systems that natively ran some other processor. (This has happened many times. And no, I don't know which processor this particular story applied to.)
Raymond Chen at The Old New Thing
So the core of the story comes down to this:
All in all, it took this program 256 kilobytes of code to initialize 64 kilobytes of data.
Raymond Chen at The Old New Thing
The people working on Windows were so offended by this, they added code to the processor emulator just to fix this program.