
156
Practical aids
to programming
Simulators
A simulator is a program designed to imitate the operation of a micro-
processor. A binary program can be loaded into a simulator and run to
produce the same result as it would do on the microprocessor
itself.
There are two main differences:
• The simulator runs some 10 000 times slower.
• The simulator prints out the result of
every
instruction, thus provid-
ing a blow-by-blow account of the action of the program.
Simulators are useful in tracking down obscure program faults, because
they help to find the exact place where the program begins to deviate
from its planned course. They are, however, expensiv ...