The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
From: Clem Cole <clemc@ccc.com>
To: Robert Clausecker <fuz@fuz.su>
Cc: TUHS main list <tuhs@minnie.tuhs.org>
Subject: Re: [TUHS] 8bc -- a B compiler for the PDP-8
Date: Mon, 23 Sep 2019 13:25:40 -0400	[thread overview]
Message-ID: <CAC20D2NMVwL-tkSTAUq0TTZtE+FG+KiCKEe-WD_b+HcmRHs9MQ@mail.gmail.com> (raw)
In-Reply-To: <20190920225350.GA26132@fuz.su>

[-- Attachment #1: Type: text/plain, Size: 2300 bytes --]

below...

On Fri, Sep 20, 2019 at 7:08 PM Robert Clausecker <fuz@fuz.su> wrote:

> Greetings!
>
> As a project for our university's seminar on the PDP-8 I wrote a
> compiler for the B language targeting it.


Very cool.

>   It's a bit rough around
> the edges and the runtime code needs some work (division and
> remainder are missing), but it does compile B code correctly,
> generating acceptable code (for my taste, though the function call
> sequence could be better).
>
A suggestion,   Load TSS/8 on to your simh system with its Algol compiler
and look at how it generated code.  I would suspect you can use Algol's
calling conventions and probably some of its runtime.   Google is your
friend.  I had it running a while back, but do not have it active at the
moment - the key is all the pieces should be findable in the wild,.


>
> I hope some of you enjoy this compiler for an important historical
> language for an important historical computer (makes me wonder why
> the two weren't married before).
>
Might have been, although when Ken created B for the PDP-7, BCPL was his
model and there were already implementations of BCPL around for a number of
processors.  I would not be surprised if there was a BCPL/8.  I would check
in the DECUS library, much of which I think can be found online these days
??bit savers??.

FWIW: IIRC, the Grenoble Algol, a DEC Fortran and DEC Focal (plus
assembler) were the languages I remember on TSS/8.  I came late and short
lived to the PDP-8 world and did not do much with it.  So there could have
been/unlikely were more.   The 8 Gordon Bell and his students had used to
write it, was in the EE Dept at the time and most unused because we hard
started to collect PDP-11s.

But I do have a fondness for the TSS/8, because on a bet, one summer
weekend in about 1976 I think, a couple of us hacked on it to make it swap
to paper tape - you got about 2-4K of storage max (the read is destructive
and much more than that the tape ripped/got tangled).  But it worked enough
we got the beers and pizza and we claimed success for proving it could be
done.   Sadly I have long ago lost that code for that hack.   The PDP-8 we
used was a very early 8 that CMU had and at one point was in donated to
Boston Computer Museum/was on display until the museum closed.

[-- Attachment #2: Type: text/html, Size: 3796 bytes --]

  reply	other threads:[~2019-09-23 17:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-20 22:53 Robert Clausecker
2019-09-23 17:25 ` Clem Cole [this message]
2019-09-23 18:01   ` Henry Bent

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=CAC20D2NMVwL-tkSTAUq0TTZtE+FG+KiCKEe-WD_b+HcmRHs9MQ@mail.gmail.com \
    --to=clemc@ccc.com \
    --cc=fuz@fuz.su \
    --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).