[TUHS] [tuhs] PDP-11 and early Unix

Angelo Papenhoff aap at papnet.eu
Tue Mar 15 05:03:08 AEST 2022


On 14/03/22, Clem Cole wrote:
> >
> > And a tip of the hatly hat for getting this:
> >
> >   Although the ++ and - operators in C are equivalents of DEC and INC
> >   instructions, they were inspired by an addressing mode in the PDP-7.
> >
> As I said, the authors seem to have done a little homework, although I was
> under the impression ??Ken?? had created them for B independently (which,
> of course, was first on the PDP-7).  The ++/-- for increment and decrement
> was just a nice notation since they are such a common occurrence in real
> code, it's handy to have. But, I did not think the PDP-7 ISA includes
> addressing modes in the same manner as the 11.  I'm probably confused, but
> I thought PDP-7  is a very simple instruction (and small) with an AC,
> Link/Indirection and a PC - it reminded me of the PDP-8 more than anything
> else [although, IIRC it could do both 1's complement and 2's - depending
> the type of AND instruction].

The PDP-7 has auto-increment registers at 10-17 that are incremented
when addressed indirectly.
I don't think it's even possible that the B runtime used them, because
of the implied indirection, which is logically separate in B.
They might still have been an inspiration, but i didn't get that
impression from the copious discussion of that topic.

aap


More information about the TUHS mailing list