PDP-11/70 Boards
Noel Chiappa
jnc at mercury.lcs.mit.edu
Wed Dec 1 11:55:07 CST 2021
> From the blog of someone who got a KB11-A working
It's Fritz Mueller's blog; at about the top of this page:
https://fritzm.github.io/category/pdp-116.html
he's just turned the machine on for the first time, and you can
follow as he chases, finds and fixes CPU problems. The KB11-C/D
of the -11/70 is _very_ similar to the KB11-A he was dealing with
(they are _basically_ the same CPU, with a cache, and other stuff
added on the other side from the CPU, on the KB11-C/D), so there
are probably some good lessons to be learned.
> dunno if Guy Steele
Ooops; sorry, Guy - the brain is starting to drop bits.
> if the particular machine the system is being built for has an FP11).
> Perhaps the later BSD versions look for the FP11 on startup, and adjust
> their behaviour appropriately, but I'm not familiar with them.
The way user code deals with the existence/non-existence of the FP11 is
pretty simple.
In C (other languages probably do something similar, but I only know about
C),one gives the '-f' flag to 'cc', and when 'cc' invokes the linker, on
machines which don't have floating point support, it uses fcrt0:
https://minnie.tuhs.org/cgi-bin/utree.pl?file=V6/usr/source/s4/fcrt0.s
as the machine language startup (the thing that calls main()) instead of
crt0. The difference is that fcrt0 sets the UNIX 'illegal instruction'
signal, in that process, to go to a handler which emulates the FP11
instructions.
In V6, as distributed, the binary of all applications which use floating
point are linked this way, so they will all run OK 'as is' on a machine with
no floating point (including those which don't suppport any kind of FP11,
such as the -11/40). When run on a machine with an FP11, there are no illegal
instruction traps, and that emulator code is just never used.
I'm not sure what the deal with BSD is, for machines without an FP11; fcrt0.s
is still included in BSD2.9, so maybe it's still using this approach. I have
this vague recollection that at some point, floating point instruction
emulation was added to the kernel, removing all the signal overhead, but that
might be a bogus recollection.
Noel
More information about the cctalk
mailing list