The Strange Birth and Long Life of Unix - IEEE Spectrum
D. Hugh Redelmeier
hugh-pmF8o41NoarQT0dZR+AlfA at public.gmane.org
Tue Dec 6 17:25:53 UTC 2011
| From: Antonio Sun <antoniosun-N9AOi2cAC9ZBDgjK7y7TUQ at public.gmane.org>
| http://minnie.tuhs.org/cgi-bin/utree.pl?file=V1
I started to read the code and was puzzled by something I found in the
first few lines: apparently redundant moves to lsh in
<http://minnie.tuhs.org/cgi-bin/utree.pl?file=V1/u5.s>
It turns out that it won't run on a PDP-11/20 without the KE11A
Extended Arithmentic Element, something I've never used. lsh is a
register in that device that causes another register pair (called mq
and ac) to shift. Without the EAE, the PDP-11/20 had only single bit
shift instructions.
The symbols are mentioned in the assembler manual
<http://minnie.tuhs.org/cgi-bin/utree.pl?file=V1/man/man1/as.1>
but not their actual meaning.
This is an interesting example of devices being addressed as if they
were memory, a noteable feature of the PDP-11.
Anyway, the moves were not redundant: each one caused a shift.
The code has lots of comments. I think later kernel assembly code had a
lot fewer.
It would have been more interesting (and alien) to me to see the PDP-7
version of Unix that preceded this one. I've never written assembly
language for the PDP-7, but I kind of know it. In some ways it is a
stretched PDP-8, something I have used. Odd fact: the PDP-7 supported
both one's complement and two's complement arithmetic.
--
The Toronto Linux Users Group. Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists
More information about the Legacy
mailing list