Discussion:
Was there ever a complete CPL compiler?
(too old to reply)
Johann 'Myrkraverk' Oskarsson
2020-05-08 21:46:25 UTC
Permalink
Dear a.f.computers,

In


https://blogs.scientificamerican.com/at-scientific-american/systems-analysis-look-back-1966-scientific-american-article/

Peter Norvig writes
The first CPL compiler emerged around 1970, and by the 1980s they were
gone.
and in

http://elearn.cs.man.ac.uk/~atlas/docs/CC_Reflections-v4%20final.pdf

George Coulouris [1] writes
Work on a CPL compiler, dubbed the 'London CPL1 Compiler'
began in mid-1963 and a working version was released in the
autumn of 1964.
and later
The London CPL1 Compiler was restricted in two ways.
1. Program size was restricted to a couple of hundred lines.
2. It had some semantic restrictions compared to the full CPL
language.
so I ask: Is Peter Norvig correct, that there really existed full
implementations of CPL in the 70s? There are more documents in
the atlas directory above, including a source code for what I
belive is the CPL1 compiler, but I don't know for certain. And
there doesn't seem to be any definite paper, at first glance, that
verifies a later compiler existed.


[1] Or that's how I read the attribution.
--
Johann | email: invalid -> com | www.myrkraverk.com/blog/
I'm not from the Internet, I just work there. | twitter: @myrkraverk
Bob Eager
2020-05-09 10:33:11 UTC
Permalink
On Sat, 09 May 2020 05:46:25 +0800, Johann 'Myrkraverk' Oskarsson wrote:

I have some stuff here:

http://www.ancientgeek.org.uk/CPL/
--
Using UNIX since v6 (1975)...

Use the BIG mirror service in the UK:
http://www.mirrorservice.org
Johann 'Myrkraverk' Oskarsson
2020-05-09 13:37:38 UTC
Permalink
Post by Bob Eager
http://www.ancientgeek.org.uk/CPL/
Thank you. I wanted to study the evolution of the C language, and
these are helpful.

It does not say anything about a compiler later than the London CPL1,
which is not the full language.
--
Johann | email: invalid -> com | www.myrkraverk.com/blog/
I'm not from the Internet, I just work there. | twitter: @myrkraverk
Bob Eager
2020-05-09 14:07:14 UTC
Permalink
Post by Bob Eager
http://www.ancientgeek.org.uk/CPL/
Thank you. I wanted to study the evolution of the C language, and these
are helpful.
It does not say anything about a compiler later than the London CPL1,
which is not the full language.
I actually started with BCPL, and it was ten years before I got into C!
--
Using UNIX since v6 (1975)...

Use the BIG mirror service in the UK:
http://www.mirrorservice.org
Gordon Henderson
2020-05-10 12:48:54 UTC
Permalink
Post by Bob Eager
Post by Bob Eager
http://www.ancientgeek.org.uk/CPL/
Thank you. I wanted to study the evolution of the C language, and these
are helpful.
It does not say anything about a compiler later than the London CPL1,
which is not the full language.
I actually started with BCPL, and it was ten years before I got into C!
Curiously I started with C ('79) before BCPl ('83)

There is this article:

https://www.lysator.liu.se/c/clive-on-history.html

and a part in it from Alan Watson (taken from an old Usenet post)

https://www.lysator.liu.se/c/alan-on-bcpl.html#cpl

which suggests CPL was never fully implemented. I've read various things that
all more or less suggest the same - ie. that CPL was a bit too ambitious for
the computers at the time and when bigger/faster systems emerged the world had moved
on (mostly to C at that time, maybe Pascal for University use for a while)

Back to BCPL - I've recently started to use it again in a retro inspired
8/16 bit computer project I'm working on. It's quite a good fit for what
I'm doing with an older CPU an smaller memory systems.

Gordon
Johann 'Myrkraverk' Oskarsson
2020-05-11 01:37:56 UTC
Permalink
Post by Gordon Henderson
Post by Bob Eager
Post by Bob Eager
http://www.ancientgeek.org.uk/CPL/
Thank you. I wanted to study the evolution of the C language, and these
are helpful.
It does not say anything about a compiler later than the London CPL1,
which is not the full language.
I actually started with BCPL, and it was ten years before I got into C!
Curiously I started with C ('79) before BCPl ('83)
https://www.lysator.liu.se/c/clive-on-history.html
and a part in it from Alan Watson (taken from an old Usenet post)
https://www.lysator.liu.se/c/alan-on-bcpl.html#cpl
which suggests CPL was never fully implemented. I've read various things that
all more or less suggest the same - ie. that CPL was a bit too ambitious for
the computers at the time and when bigger/faster systems emerged the world had moved
on (mostly to C at that time, maybe Pascal for University use for a while)
Thank you.

I also came across this[1], a slideshow from a lecture, apparently. On
page 49 of the pdf, it says
Post by Gordon Henderson
Cambridge never succeeded writing a working CPL compiler.
and web searches seem to indicate there's no current compiler for it
either.

[1] http://www.pvv.org/~oma/HistoryAndSpiritofC_ECC_Sep2017.pdf
Post by Gordon Henderson
Back to BCPL - I've recently started to use it again in a retro inspired
8/16 bit computer project I'm working on. It's quite a good fit for what
I'm doing with an older CPU an smaller memory systems.
Interesting, is any of that work public?
--
Johann | email: invalid -> com | www.myrkraverk.com/blog/
I'm not from the Internet, I just work there. | twitter: @myrkraverk
Ahem A Rivet's Shot
2020-05-11 05:14:30 UTC
Permalink
On Mon, 11 May 2020 09:37:56 +0800
Post by Johann 'Myrkraverk' Oskarsson
Post by Gordon Henderson
Cambridge never succeeded writing a working CPL compiler.
and web searches seem to indicate there's no current compiler for it
either.
The story among Cambridge CST students around 1980 (Clive Feather
and I took that course in the same year) that Martin Richards created
BCPL because CPL couldn't be implemented as designed but a stripped down
single type variant could and doing that might be a path to to a CPL
compiler.
--
Steve O'Hara-Smith | Directable Mirror Arrays
C:\>WIN | A better way to focus the sun
The computer obeys and wins. | licences available see
You lose and Bill collects. | http://www.sohara.org/
Bob Eager
2020-05-11 08:15:00 UTC
Permalink
On Mon, 11 May 2020 09:37:56 +0800 Johann 'Myrkraverk' Oskarsson
Post by Johann 'Myrkraverk' Oskarsson
Post by Gordon Henderson
Cambridge never succeeded writing a working CPL compiler.
and web searches seem to indicate there's no current compiler for it
either.
The story among Cambridge CST students around 1980 (Clive Feather
and I took that course in the same year) that Martin Richards created
BCPL because CPL couldn't be implemented as designed but a stripped down
single type variant could and doing that might be a path to to a CPL
compiler.
That is what I have always understood, and I am pretty sure I got that
from Martin. I didn't go to Cambridge, but spent a year at Essex, where
BCPL was very strong, and worked on the pretty comprehensive Essex BCPL
compiler as part of my M.Sc.

I also ran a BCPL User Group for some years.
--
Using UNIX since v6 (1975)...

Use the BIG mirror service in the UK:
http://www.mirrorservice.org
Gordon Henderson
2020-05-11 08:37:59 UTC
Permalink
Post by Johann 'Myrkraverk' Oskarsson
Post by Gordon Henderson
Back to BCPL - I've recently started to use it again in a retro inspired
8/16 bit computer project I'm working on. It's quite a good fit for what
I'm doing with an older CPU an smaller memory systems.
Interesting, is any of that work public?
Not yet but it's in a more or less working state on a 65c816 CPU
with 512KB of RAM.

Background to the project started on a 65C02: https://projects.drogon.net/6502-ruby/

65816 Board picture:

Loading Image...

CPU runs at 16Mhz.

Quick demo (taken from a B program 'back-ported' to BCPL :)

(Well, quick is relative - this takes 20 seconds to run - it's a full 32-bit implementation
of the current compiler with a cintcode VM)


GET "libhdr"


LET start() = VALOF
{
LET cx,cy,x,y,x2,y2 = ?,?,?,?,?,?
LET iter = ?

LET xmin,xmax,ymin,ymax,maxiter,dx,dy = ?,?,?,?,?,?,?

xmin := -8601
xmax := 2867
ymin := -4915
ymax := 4915

maxiter := 32

dx := (xmax-xmin)/79
dy := (ymax-ymin)/30

cy := ymin
WHILE cy <= ymax DO
{
cx := xmin
WHILE cx <= xmax DO
{
x := 0
y := 0
x2 := 0
y2 := 0
iter:=0
WHILE iter < maxiter DO
{
IF x2+y2 > 16384 THEN
BREAK

y := ((x*y)/2048)+cy
x := x2-y2+cx
x2 := (x*x)/4096
y2 := (y*y)/4096
iter := iter + 1
}
sawrch (' '+iter)
cx := cx + dx
}
sawrch ('*n')

cy := cy + dy
}

// sys (Sys_quit, 0)
RESULTIS 0
}


=== output ===

!!!!!!!!!!!!!!!"""""""""""""####################################""""""""""""""""
!!!!!!!!!!!!!""""""""""########################$$$$$%(&&%%$$$$$######"""""""""""
!!!!!!!!!!!!"""""""#######################$$$$$$$$%%%&)@(&&'%$$$$$######""""""""
!!!!!!!!!!""""""#######################$$$$$$$$$%%%%&'(*00*'&%%$$$$$$######"""""
!!!!!!!!!"""""######################$$$$$$$$$$%%%%&')*+2@@,)(&%%%$$$$$$#######""
!!!!!!!!""""#####################$$$$$$$$$$%%%&&&''),@@@@@@@,'&%%%%%$$$$########
!!!!!!!"""#####################$$$$$$$$$%%&''''''()*,@@@@@@@*(('&&&&&&%$$$######
!!!!!!"""###################$$$$$$$%%%%&&'*34.,+@@1@@@@@@@@@;@***@7)(()0)'%$$#####
!!!!!!"##################$$$$%%%%%%%%&&&'()@@@@@@@@@@@@@@@@@@@@@@@@@@@,(%%$$####
!!!!!"###############$$$%%%%%%%%%%%&&&'(+@-@@@@@@@@@@@@@@@@@@@@@@@@@=+('&%%$$###
!!!!"##########$$$$$%%&(.'''''''''''''(*,5@@@@@@@@@@@@@@@@@@@@@@@@@@@@+)-&%$$###
!!!!"####$$$$$$$$%%%%&&(.2,.*+10++*)))*.>@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@2+&%$$$##
!!!!##$$$$$$$$$%%%%%&''()9?@@@@@@@@@,,-@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@-*&%$$$##
!!!!#$$$$$$$$%%%%%&,(()+1@@@@@@@@@@@@@3@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@79'%%$$$$#
!!!#$%%$$$%&&&&&''().1?2<@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@*'&%%$$$$#
!!!()**,+9652/1//35>@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@4+)'&&%%$$$$#
!!!#$%%%$%&&&&&'''()***@3?@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@)'&%%$$$$#
!!!"$$$$$$$$%%%%%%&+())+1@@@@@@@@@@@@@4@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@2&%%$$$$#
!!!!##$$$$$$$$$%%%%%&''()=<@@@@@@@@@.,-@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/0&%$$$##
!!!!"####$$$$$$$$%%%%&&(,419*+/@+.*)))*.;@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@5)&%$$$##
!!!!"#########$$$$$$%%&(-(''''(''''''((*-4@@@@@@@@@@@@@@@@@@@@@@@@@@@4+)-&%$$###
!!!!!"###############$$$%%%%%%%%%%&&&&'(,@.@@@@@@@@@@@@@@@@@@@@@@@@@1+('&%%$$###
!!!!!!"##################$$$$%%%%%%%%&&&'()7@@@@@@@@@@@@@@@@@@@@@@@@@@+'%%$$####
!!!!!!""####################$$$$$$%%%%%&&'+94/-+***@3@@@@@@@@@@@1@@))))-*'%$$#####
!!!!!!!"""#####################$$$$$$$$%%%&''''''()*,@@@@@@@*)('&&&&&&%$$$######
!!!!!!!!""""#####################$$$$$$$$$$%%%&&&''(,@@@@@@@+'&&%%%%%$$$########
!!!!!!!!!"""""######################$$$$$$$$$$%%%%&'*++3@@,))&%%%$$$$$$#######""
!!!!!!!!!!""""""#######################$$$$$$$$$%%%%&'(*..*'&%%$$$$$$######"""""
!!!!!!!!!!!""""""""#######################$$$$$$$$%%&&)@(''(%$$$$$$#####""""""""
!!!!!!!!!!!!!""""""""""#######################$$$$$$%+'&%%$$$$$######"""""""""""
!!!!!!!!!!!!!!!""""""""""""#####################################""""""""""""""""



Gordon

r***@gmail.com
2020-05-11 03:46:48 UTC
Permalink
Post by Gordon Henderson
Post by Bob Eager
Post by Bob Eager
http://www.ancientgeek.org.uk/CPL/
Thank you. I wanted to study the evolution of the C language, and these
are helpful.
It does not say anything about a compiler later than the London CPL1,
which is not the full language.
I actually started with BCPL, and it was ten years before I got into C!
Curiously I started with C ('79) before BCPl ('83)
https://www.lysator.liu.se/c/clive-on-history.html
and a part in it from Alan Watson (taken from an old Usenet post)
https://www.lysator.liu.se/c/alan-on-bcpl.html#cpl
which suggests CPL was never fully implemented. I've read various things that
all more or less suggest the same - ie. that CPL was a bit too ambitious for
the computers at the time
CPL was fairly similar to Algol.
ALGOL 60 was implemented on DEUCE, which had 384 words
of high-speed store and a magnetic drum of 8K words.
Size of machine is unlikely to have been an issue.
Post by Gordon Henderson
and when bigger/faster systems emerged the world had moved
on (mostly to C at that time, maybe Pascal for University use for a while)
Back to BCPL - I've recently started to use it again in a retro inspired
8/16 bit computer project I'm working on. It's quite a good fit for what
I'm doing with an older CPU an smaller memory systems.
Bob Eager
2020-05-11 08:13:18 UTC
Permalink
Post by r***@gmail.com
CPL was fairly similar to Algol.
ALGOL 60 was implemented on DEUCE, which had 384 words of high-speed
store and a magnetic drum of 8K words.
Size of machine is unlikely to have been an issue.
I think a lot of it was due to the distributed nature of the work. It
took place in two separate universities (the joke was that CPL stodd for
'Cambridge Plus London'), and there were differences of opinion even
within one of the institutions.

(there is another joke which references Strachey, saying that CPL stood
for 'Christopher's Programming Language')
--
Using UNIX since v6 (1975)...

Use the BIG mirror service in the UK:
http://www.mirrorservice.org
Loading...