BCPL evolved from CPL. (2021) [pdf]
cl.cam.ac.uk
cl.cam.ac.uk
"Not beautiful and much hated by some" is a masterful piece of understatement.
This is what a GLOBAL declaration looks like:
GLOBAL
$(
printf : 89
programmeriq : 90
$)
You're reading that correctly. There is no symbolic linkage in the language. You declare the specific numeric slot in a global array you think your function or global variable should occupy. You hope nobody else uses the same ones. That's how you call functions defined in other compilation units.I also assisted in bootstrapping BCPL on a self-built machine, and it was so easy. I liked it, though I'm not sure I'd go back to it.
I also chatted with Martin Richards for a while about MCPL, but never found the time to dive into that.
Fun times.
Richards wanted to build a flight simulator a while back, so he added floating[1] point. Richards 1 - Yaks 0: that yak got shorn.
[0] I guess I should ask Richards how much influence he got from Backus?
[1] would Moore have done it in fixed? or are there stability problems with that?
(the EE's of the time had not yet perfected their art sufficiently for CPL to have been viable for personal computing; does it work better now that we have GHz and GB?)
Mr. Richards got himself a GP2X after a while, and then saw how folks were porting BCPL all over the place, and I think he kind of got a big kick out of that .. we fell out of touch, but it was really a worthwhile effort to port BCPL like that, and attract the attention of the master ..
Martin Richards, How BCPL Evolved from CPL, The Computer Journal, Volume 56, Issue 5, May 2013, Pages 664–670, https://doi.org/10.1093/comjnl/bxs026
Published: 20 March 2012 (not 2021)
Did he invent time sharing? He presented a very influential paper on the topic at the 1959 UNESCO International Conference on Information Processing in Paris. But, John McCarthy says he was already thinking about the topic in 1955. [0] And John Backus proposed the idea at an MIT conference in 1954. [1]
So, while no doubt he played a big role in popularising the concept, it is questionable whether he actually "invented" it. Maybe, he came up with the idea independently of McCarthy and Backus – but if that is true, it isn't clear that he thought of it first
[0] https://www-formal.stanford.edu/jmc/history/timesharing/time...
[1] https://bitsavers.org/pdf/mit/whirlwind/summer_session_1954/... see PDF page 78, in particular "John Backus said that by time sharing, a big computer could be used as several small ones; there would need to be a reading station for each user" (my emphasis)
Also the original AmigaDOS was written in BCPL. This caused some complications later when they decided to use C as the primary system programming language. In AmigaDOS BCPL pointers are "word" (2 byte) addressed, which was a common form of addresses for computers of the time (inherited from non-power of two sized word computers such as the 36-bit machines of the 60s and 70s). C uses byte addressing, so it requires a bit shift to convert between BCPL's word addressed pointers and C's byte addressed pointers.
A third party company, MetaComCo, was known to be selling a a MC68000 port of TRIPOS (which was written in BCPL because its author created BCPL), so they shoehorned TRIPOS into the Amiga operating system and called it AmigaDOS.
It was basically a black box. AmigaOS had an open, documented, normal way to operate, with shared libraries and devices, relocatable executables, callable from any language, including C - because all parameters were passed in registers and each function had to explicitly declare which registers were used, so none of this "I'll write it in C, and if you call me, just remember to use my C compiler's calling convention" nonsense that is now standard practise and people using other languages say C is over-privileged because it's base-level glue... on a single-architecture system like the Amiga, register declarations are base-level glue!
However, any time you went near AmigaDOS, it was quirky crap where all pointers were divided by 4 (because in BCPL there are no datatypes, just machine words, and machine word 0 is 4 bytes after machine word 1 on a 8-bit byte-addressable machine with 32-bit machine words), and there was the "global vector" for accessing shared functions, rather than standard Amiga libraries.
Amiga Inc. were pushed into rewriting in C by Charlie Heath et al, founders of the "AmigaDOS Replacement Project" (ARP)... ultimately almost all of AmigaDOS and its utility commands were rewritten in C for AmigaOS 2.0, and dos.library grew substantially in functions (most of which were already in AmigaDOS, but not visible outside BCPL code)