User Tools

Site Tools


anecdotes:a.out_percolate

a.out?

(taken from Dennis Ritchie's home page)

Back around 1970-71, Unix on the PDP-11/20 ran on hardware that not only did not support virtual memory, but didn't support any kind of hardware memory mapping or protection, for example against writing over the kernel. This was a pain, because we were using the machine for multiple users. When anyone was working on a program, it was considered a courtesy to yell “A.OUT?” before trying it, to warn others to save whatever they were editing.

[A substory: at some point several were sitting around working away. Bob Morris asked, almost conversationally, “what are the arguments to ld?” Someone told him. We continued typing for the next minute, as a thought began to percolate, not quite to the top of the brain – in other words, not quite fast enough. The terminal stopped echoing before anyone could stop and say “Hold on Bob, what is it you're trying to do?”]

We knew the PDP-11/45, which did support memory mapping and protection for the kernel and other processes, was coming, but not instantly; in anticipation, we arranged with Digital Special Systems to buy a PDP-11/20 with KS-11 add-on. This was an extra system unit bolted to the processor that made it distinguish kernel from user mode, and provided a classical PDP-10 style “hi-seg” “low-seg” memory mapping unit. I seem to recall that maybe 6 of these had been made when we ordered it.

Those who remember the early PDP-11s remember that there were no multiply, divide, or shift-by-more-than-1 instructions, and that they had an optional EAE (“extended arithmetic extension”) gadget, the KE-11A, that appeared in physical memory in the I/O device space: one stored the operands here and read back the answer there (in fact at 777302 and following addresses).

One problem the KS-11 had to deal with was that ordinary programs needed to do multiplies and divides, yet shouldn't be allowed to access the I/O device space. So it included circuitry that detected just the EAE addresses, and remapped them to physical, while all other virtual addresses in user mode were mapped.

When we got the KS-11 machine, the EAE just didn't work at all. With test programming, we got bus errors, or no action from the EAE unit. But, in those days when you bought such things from Digital Special Systems, you also got the circuit drawings, so after a lot of headscratching and fiddling, they were consulted.

It turned out that on one page of the drawings, there was an address comparator for the EAE address, with an out-of-page arrow labelled “EAE ADDRESS DETECTED H”. On another page, there was an in-arrow labelled “EAE ADDRESS DETECTED L”. We couldn't find anything between these.

In the end, we had a visit from an embarrassed Digital Special Systems guy who found an unused inverter pin and added some white wires.

These days, such a problem would be harder to fix in the field.

anecdotes/a.out_percolate.txt · Last modified: 2016/01/12 10:34 by wkt