The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: Angelo Papenhoff <aap@papnet.eu>
To: tuhs@minnie.tuhs.org
Subject: Re: [TUHS] [EXT]  "The programmer must have been carried away ...
Date: Wed, 23 Jun 2021 22:08:51 +0200	[thread overview]
Message-ID: <YNOU0yG0MK6F54FY@indra.papnet.eu> (raw)
In-Reply-To: <F46AB5BC-C48F-4060-AA26-DF802E62B14C@hotmail.co.uk>

On 23/06/21, silas poulson wrote:
> I’m aware line 2238’s famous “You are not expected to understand
> this.” Comment is due to odd PDP-11/45 behaviour.

Actually there are two different takes on what it is exactly that you're
not expected to understand. The "obvious" one in Lions' book, (i.e. saved
stack being overwritten when swapping so you have to restore from the
special swap-saved stack), but dmr had a different take on it, that it
had to do with functions really not being happy if you switch the stack
underneath them. You can find dummy variables in the interdata port that
make sure the stack frames of some functions (newproc and swtch?) match.
So not really a hardware thing but a consequence of the compiler.

> Do you know if other sections of the C show remnants of B or the PDP?
> Or is it just those spots?

For the kernel I'm just aware of this one. printf was copied over a
number of times (the c compiler also includes a version) but the kernel
was never written in B, so i wouldn't expect any B-ness in there
otherwise.

aap

      parent reply	other threads:[~2021-06-23 20:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-23 16:01 [TUHS] " Angelo Papenhoff
     [not found] ` <F46AB5BC-C48F-4060-AA26-DF802E62B14C@hotmail.co.uk>
2021-06-23 20:08   ` Angelo Papenhoff [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YNOU0yG0MK6F54FY@indra.papnet.eu \
    --to=aap@papnet.eu \
    --cc=tuhs@minnie.tuhs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).