Annotated Elliott 903 Algol System

This document is an overview of an annotated version of original Elliott documents describing the Algol 60 system developed for the Elliott 903 computer from the 1960s.

The Elliott 903 Algol system was written under contract to Elliott Automation by CAP (Computer Analysts and Programmers), an external software house. The primary authors of the system were Don Hunter and Norman Spink.

The source code of the Algol system has survived as a collection of paper tapes, containing in total around 15,000 lines of Elliott 903 Symbolic Input Routine (SIR) assembly code. The code is very terse, with limited layout and almost no comments. The system was punched in this form to reduce the amount of paper tape handling required to build the system and also because it was Elliott practice to write separate documents describing the code and to draw flowcharts to aid explanation.

As well as the source code of the Algol system, the documentation written by the designers of the system has also survived. This comprises type-written notes describing the working of the system in some detail and hand-written flow charts for the main routines in the system.

In the "annotated" Elliott Algol System, as described in this note, the original documents have been converted to HTML and/or PDF so that they can be read using a modern web browser. Additionally, to aid intelligibility, HTML "links" have been set up so that the reader can cross-reference blocks of source code with the corresponding descriptions, specifications and flowcharts. Similarly links are provided in the descriptions and specifications to cross refer to the source code they describe. Within the source code itself, each use of an identifier is a hot link to the definition of that identifier (e.g., as a constant, variable or subroutine) in the source.

Elliott 903 Algol 60

The Elliott 903 Algol 60 system implements the "IFIP Subset" of Algol 60. The subset introduces various restrictions including requiring identifiers to be declared before first reference, recursive procedures disallowed, no own variables. Despite these restrictions, Elliott 903 Algol remains a useful language for numerical computing.

The Elliott 903 Algol system is described in the Elliott 900 Technical Manual. Volume 2, Section 1, Part 2 describes the facilities and restrictions of Elliott 903 Algol and instructions for operating the paper tape based Algol 60 system. It should be read first to understand the overall structure and operation of the Elliott Algol 60 system.

Volume 2, Part 1, Section 1 Appendix A describes the SIR assembly code notation.

Volume 1, Part 2, Section 2 describes the architecture and instruction code of the Elliott 903.

Readers unfamiliar with the 903 and SIR should read the above two documents before going on to explore the Algol system in detail.

The Elliott 903 Algol System

The Elliott Algol system is self-evidently based on the KDF9 Whetstone Algol System, as described in Randell, B. and Russell, L.J., "Algol 60 Implementation", A.P.I.C. Studies in Data Processing, No. 5, Academic Press, London and New York, 1964. Algol source code is translated to a pseudo-code for execution by a stack-based runtime interpreter. While the KDF9 translator uses a precedence grammar for parsing, the Elliott Algol translator is recursive descent in nature. The pseudo-codes are very similar, including the names of the primitive operations. The Elliott interpreter is a little simpler than the KDF9 version, due to the restrictions imposed on Elliott Algol.

In addition to the translator and interpreter there is a runtime library containing the standard Algol 60 functions, such as entier, sin, cos, etc., and additional procedures and functions defined by Elliotts mostly concerned with input-output. Sadly source code for the library has not been found and so is not included.

The simplest version of the Elliott Algol system is a two-pass system intended to be run on an Elliott 903 with 8K of memory: other versions for machines with larger memories are described in the Elliott Technical Manual. The first pass embodies the translator and emits the pseudo code as an intermediate tape for subsequent reading the the interpreter. It is the code for the two-pass system that has been annotated.

To understand the Elliott Algol system start by reading the Elliott 903 Object Code Manual as this defines the interface between the Translator and the Interpreter.

To understand how the pseudo code is generated, read the translator description in parallel with the annotated translator source code. and associated flowcharts

To understand how the pseudo code is executed, read the interpreter description in parallel with the annotated interpreter source code and associated flowcharts.

NOTE: The source code for the Elliott Algol system is the last major version (Issue 6) released by Elliotts. (There was a subsequent release of a revised, Issue 7, Library tape). The handwritten documentation and the flow charts date back to the initial releases of the system and there are some discrepancies between these and the code - mostly fixing errors encountered in the code after the initial release. At Issue 6 there was a significant change in the Interpreter, when the global workspace was moved higher in the store - this is explained in the section of the programming manual dealing with writing code procedures. Since the code references the workspace using labels this is mostly transparent to the documentation, but be wary of statements made about the contents of specific absolute addresses. In all cases the source code is authoritative and has been validated against the issued binary paper tapes.

Other Elliott Documentation

There is an extensive archive of Elliott documentation at Elliott 900 Series Computers Document Archive.

Summary of Emulation Facilities

There is an online facility that allows you to type in an Algol program, then translate and run it.

There are also facilities for running an emulated Elliott 903 on your own computer and an extensive archive of Elliott software, including all the major language systems and utility software provided by Elliotts to customers.

The most comprehensive emulator is written for Windows 7 and Windows 10. It includes a large suite of canned demonstrations of all the software in the software archive. It comes with a detailed manual. The less experienced user will probably be content to install the emulator and run the demonstrations. For the more experienced user it is possible to write you own scripts to add further demonstrations, debug them and deal with conversions between the various data formats used by the emultor.

A simpler and more portable emulator has been written in C and intended to run in Unix command line environments such as Linux and MacOS (terminal command). It comes with a small number of demonstrations and by using these as an example, the more experienced user will be able to write their own shell scripts to run programs.

Last edited: 4th April 2024 - Andrew Herbert