From: Paul Koning
Sent: Monday, February 26, 2018 12:19 PM
> On Feb 26, 2018, at 12:06 PM, Doug Ingraham via
> <cctalk at classiccmp.org>> wrote:
> The purpose of an emulator is to accurately
pretend to be the original
> hardware. It doesn't matter that the original OS runs on a particular
> emulator. If a program can be written that runs on the original hardware
> but fails on the emulator then there is a flaw in that emulator.
That's true. But it is unfortunately also true
that creating a bug for bug
accurate model of an existing machine is extremely hard.
This is true even in real hardware (or "real" hardware, if you prefer), whether
bug-for-bug or simply correct results for corner cases.
The XKL Toad-1 System was designed to be a superset clone of the KL-10 based
DECSYSTEM-2065 from Digital Equipment Corporation. It implements the full
30-bit extended addressing introduced with TOPS-20 v4, of which the KL-10
provided a 23-bit subset, and provides native support for 10Mbit Ethernet and
FASTWIDE differential SCSI2 (both state of the art in 1991 when the design was
As a better DEC-20, the Toad-1 was a success. (We will leave aside the issue
of its market failure, which is irrelevant to the story.)
Fast forward 20 years, to Living Computer Museum, where a KI-10 based DEC-1070
was undergoing restoration. Diagnostics were needed, so the resident TOPS-20
programmer laid hands on the MAINDEC sources for the KI-10 and proceeded to
compile them all and generate paper tapes of the results. All went smashingly
well until the multiplication test.
The diagnostic source for this test uses a macro to build a set of test values
for X**2 where X is a power of 2. Internally, Macro-20 uses the IMULM
instruction to build the results. In the KA-10 manual, IMULx of 2**35 * 2**35
is supposed to store the high order part of the result into the 36 bit word
addressed by the instruction, and set the overflow bit.
On the Toad-1 (and on the Toad-2 prior to our discovery of this bug), a zero is
stored instead. Since we compiled the KI-10 diagnostics on the Toad-1, this
incorrect result was placed on the diagnostic paper tape, and the KI-10 seemed
to fail the diagnostic. Imagine our chagrin when days of trying to correct the
problem led to the conclusion that the diagnostic was incorrect.
Vintage Computing Sr. Systems Engineer
Living Computers: Museum + Labs
2245 1st Avenue S
Seattle, WA 98134
mailto:RichA at LivingComputers.org