Simulated Systems - Full System Simulation This is opcode.c from Hercules And here is a corresponding instruction implementation More complete simulators use lower-level primitives A simulator is a user-space program A simulator should probably be portable