mirror of
https://github.com/simh/simh.git
synced 2026-02-18 21:38:16 +00:00
The original idling model called sim_idle() within the context of a scheduled event running on the CPU unit. The overhead of scheduling and the related dispatch serve no specific purpose. Meanwhile, the 'work' involved in determing if idling is possible is about equivalent to the work of executing an additional instruction. Therefore sim_idle is invoked with an argument which causes the sim_interval to be adjusted by 1 on each call that doesn't actually perform an idle sleep. This adjustment keeps the calibrated instruction execution rate consistent with other purely non-idle instruction mixes.
138 KiB
138 KiB