The SSMC Simulator

Below, the SSMC is busy computing the inner product of two 3D vectors. The simulator reads the instruction indicated by the arrow, executes it, and adds one to the instruction. Finally, it prints itself: the processor on top and the memory below.

The Python source code for the simulator producing this output is available here. The word "simulator" may be a slightly grand term for this short program. It is certainly not simulating the SSMC at the hardware level. By design the SSMC instructions are not only close to statements from a high level programming language but actually valid Python code. The SSMC simulator simply executes the instructions using Python. The one exception is the "halt" instruction which stops the simulation when encountered. "goto" is also a bit special since a Python function was defined for this instruction.