A glimpse back in time: an overview of the EDSAC

The Electronic Delay Storage Automatic Calculator (EDSAC) was one of the world’s first full scale electronic computer to implement the stored-program principle which states that both data and program are to be stored in the computer’s main memory and accessed during runtime. It was built by Professor Maurice Wilkes (1913 – 2010) and his team at the Mathematical Laboratory of the University of Cambridge in the United Kingdom. EDSAC, which occupied room five by four meters, did its first calculation on 6 May 1949 when it calculated a table of squares and a list of prime numbers and it was David Wheeler (1927 – 2004) who wrote its very first program. The machine ran until 1958, when it was finally switched off.

A large part of the design of the EDSAC was based upon John von Neumann’s report First Draft of a Report on the EDVAC which contained the first published description of the logical design of a computer using the stored-program concept, known as the “von Neumann architecture”. Few months after reading von Neumann’s report, Wilkies attended a workshop at the University of Pennsylvania’s Moore School of Engineering, where ENIAC (the world’s first general-purpose electronic computer) had been built, and even more advanced computer, the EDVAC, was being constructed. While EDVAC was being constructed by a large team of engineers and its construction consumed large budget, Wilkies had a very modest budget within which to work and only few assistants. However, he was more interested in using an advanced computer to solve real scientific problems rather than becoming an expert computer-maker as such. For all these reasons, Wilkies decided to construct his own scaled-down version of EDVAC, called EDSAC, and to do it as quickly as his limited resources would allow.


Architectural structure


Fig. 2.1 The EDSAC architecture

Following the structure of all stored-program computers, the EDSAC consisted of a processor, a memory (store), and input-output devices, as shown on Figure 2.1.

First, the whole architecture of the EDSAC was based on the memory. The memory storage was constructed of 32 mercury delay lines (also known as tanks), built in two batteries of 16 tanks each. They were several feet long, sealed glass tubes, filled with mercury which represented data as ripples in the mercury. These tubes had transducers (a combination of loudspeaker and microphone) at either end. Data was sent to the transducer at one end of the tube, and the transducer would pulse and generate a small wave in the mercury. The wave would quickly travel to the far end of the tube, where it would be read back out by the other transducer and sent back to the computer. Mercury was chosen because of its acoustic properties which allowed no reflection of the waves. It should be noted that using these delay lines resulted in having a sequential data stream. Compared to the earlier Karl Zuse’s machines in which both operands were processed in parallel, EDSAC was a sequential machine and each bit was sequentially sent one after the other. Although that system was not so good in sense of speed, it was more reliable and there was a huge benefit in terms of hardware, because less hardware was needed when data was processed sequentially. Each delay line was capable of storing 32 words of 18 bits (each word could be either data or instruction), but because of the way that memory was implemented it was not possible to use all of the bits and the first bit was always lost. Hence, the total memory capacity of the EDSAC was 1024 memory locations which was equivalent to about 2 kilobytes.

Second, the processor of the EDSAC possessed control and arithmetic-logic (ALU) units composed of approximately 3,000 vacuum tubes arranged on 12 racks. There were five principal registers: the Sequence Control Register, the Order Tank, the Multiplicand and Multiplier registers and the Accumulator. The control unit’s task was to read the instruction value (the sequential stream of 18bits) from the delay line memory and to store it into the Order Tank Register. What instruction was being executed was controlled by the Sequence Control Register, which basically pointed to the point in the delay memory from which these 18 bits to be taken. Moreover, the EDSAC had an accumulator based architecture, which meant that one operand was fetched from memory and the result from the calculation was stored back into the accumulator. Although no dedicated divider was included in the design of EDSAC in order to simplify the structure of the machine, it had a dedicated multiplier unit, consisting of a multiplier and multiplicand registers. Because of the accumulator-based architecture of the machine, the multiplication was carried out by having the value in the multiplier register times a memory location. The value stored in memory was first loaded into the multiplicand register, before the multiplication took place, while the result of the whole calculation was stored in the accumulator. The same technology of mercury delay lines was also used for the processor registers, although the delay lines were much shorter as they stored only a few bits of information. Therefore, the two types of delay line were known as long and short tanks.

Third, EDSAC used an ordinary five-hole telegraphic punched tape, read by a photoelectric tape reader for input. Each row of holes represented a five-digit binary number and the basic input operation was to transfer this number to the store. Similarly, the output mechanism was delivered by a teleprinter.

Finally, the machine ran at clock speed of 500 kHz. Wilkies noted that he would have been happy to accept the challenge of working at 1 MHz as most other early designers were doing but preferred a straightforward development to permit early experiments with the writing of programs to solve real scientific problems.

Number representation

It should be noted, that in common with all the early stored-program computers, EDSAC had only fixed-point operations and floating numbers were not used. Instead, real numbers were stored as fractions in the range -1 ≤ x < 1.

Internally, the EDSAC used two’s complement, binary numbers. Although all internal operations were carried out in the scale of two, the machine accepted numbers in the scale of ten and carried out the necessary conversion to the scale of two automatically. Similarly, it converted output data into the scale of ten before printing takes place. There were four different number formats used: short integers, long integers, short fractions and long fractions. It was mentioned above that out of the 18 bits that composed a word, the first one was always lost, so only 17 bits were available. Short integers were exactly 17 bits long, of which the leftmost bit represented the sign of the number (“0” for positive and “1” for negative) and the rest 16 bits its numerical value. In case when these 17 bits were not enough, it was possible to combine two memory locations together with the so called “sandwich bit”, resulting in having a long number of 35-bit length. Short and long fractions were stored in a similar way.

Within the ALU unit, the multiplication registers had a capacity of 35 bits each, while the accumulator had a capacity of 71 bits, thus being sufficient to develop the full product of a pair of long numbers without losing any precision.

In EDSAC, there was no way of detecting if a calculation produced a result that was greater in magnitude than that the register can store or represent (the so called “overflow”).

Instruction set features









Fig. 2.2 The Instruction format of the EDSAC

Operations in EDSAC were represented by letters of the alphabet, mapped as much as possible to the functionality of the instruction – for example A was used for Add, S was used for Subtract, T was used for Transfer, etc). The binary representation of the opcode was in fact the same as the character code of the corresponding character which simplified the translation of the symbolic program considerably. Instructions were always written in a symbolic form such as S 49 F, for example, where “S” stood for subtract, “49” referred to the memory location and the length indicator “F” was used to specify a short operand (“D” represented long number).

A single-address code for orders was used in the EDSAC, so that each order had reference to at most one location in the memory. Inside the machine orders were expressed as a 17-bit binary number, thus being of the same length as short numbers. As shown in Figure 2.2 the five most significant bits represented the function of the order – add, subtract, etc. The sixth bit was an unused spare bit (“0” by default). The next ten bits gave the address of the storage location to which the order refers. The last bit specified the operand length (“0” if the order referred to a short 17-bit word and “1” if the order referred to a long 35-bit word).

There were 17 instructions available in the EDSAC: add, subtract, multiply, collate, shift left, shift right, load multiplier register, store accumulator, store and clear accumulator, conditional skip, read input tape, print character, round accumulator, no-op and stop. There was no division instruction and no way to directly load a number into the accumulator.

Role of the initial orders

The reason EDSAC is still regarded as the first practical computer is that it had an idea of an assembly language. Compared to earlier machines in which everything was represented by a raw binary code, EDSAC had textual representations of instructions. It was actually the first machine to have a human readable program, rather than just a sequence of 1s and 0s that were difficult to translate. Therefore, a huge benefit was that the code was more debuggable, compared to older machines.

From what has been said and from an examination of the order code, it was noted that the input mechanism was controlled by program orders. Unless, therefore, there were some orders in the memory at the beginning of the computation, the machine could not start. For this reason, there was a sequence of instructions, known as initial orders, permanently wired onto a set of uniselectors (a mechanical read-only memory). These initial orders consisted of 31 instructions and assembled programs in symbolic form from paper tape into the main memory and set them running.

Under the control of the initial orders the machine converted the numerical part of the order to binary form and assembled the order with the function digits and the numerical digits in their correct relative positions. The initial orders also determined the way in which the instructions were punched on the paper tape, and this was quite an advance for this period.

Moreover, a major invention by D.J. Wheeler was the so called subroutine library. As many programs consisted of similar stages of dealing with a particular problem, it was convenient to have some sort of a library containing sequences of orders for performing standard operations. Considering the fact that these subroutines have been previously tested it could be assumed that they were free from errors and the chance of an accidental error was minimized as much as possible. Therefore, the subroutines considerably simplified the preparation of long programs.


By the time Wilkies and his team completed their machine, they realized that not writing programs but getting them down to work was the hardest part, simply because there were bugs, programs tended to go wrong. Two common types of bugs known as control errors and numerical errors could be distinguished. The control errors usually occurred when there was a problem with the program logic and a sequence of instructions deviated from the intended program path. Numerical errors usually occurred when there was a fault in the numerical methods used, thus resulting in wrong calculations. Several ways of dealing with these problems were implemented in EDSAC.

Useful feature of the EDSAC’s architecture was that it was possible to display the contents of the store and the registers on Cathode Ray Tube (CRT) monitors. These monitor tubes were very important way of observing the progress of the program and debugging it, an approach that was known as peeping. Although innovative, this approach was time consuming and more error-prone because it was quite difficult to navigate around the monitor tube and it took a lot of practice to understand instructions accurately from the registers. Furthermore, once the error was spotted, the program text had to be corrected before it could be retested. For all these reasons, software debugging aids were soon invented.

Another debugging approach was the so called terminal dump or post-mortem, which involved printing out a region of the memory after the execution of the program had been terminated. That routine was loaded by the initial orders in the usual way.

The third debugging approach was called checking routines and used the idea of tracing which enabled people to print out diagnostic information while the program was being executed. Instead of obeying the orders of a program directly by the control circuits of the EDSAC, they were obeyed by an interpretive program or a simulator. Although that technique needed a little forethought, once mastered it was really effective dealing with bugs.


As seen above, EDSAC was a pioneering machine, although it used the idea of a von Neumann architecture that was already around. EDSAC became the world’s first full-scale computer that performed electronic binary computations while storing its program and data in the same memory. That is why, the invention of the mercury delay lines used was crucial because the only way to store instructions and data in the same memory, was to have a big memory. Compared to the earlier Karl Zuse’s machines, for example, were the punched tape was the memory and instructions were stored on tape, EDSAC executed the program directly from memory and used the tape just as a mechanism to load it into memory. It was now possible to move from paper tape to memory. One of the advantages of moving the program into memory was that it allowed people to have more control and analyze how the program was executed. Furthermore, another advantage was that the clockspeed was increased. While in Zuse’s machines the time of fetching instructions was limited due to the use of mechanical device, in EDSAC you could fetch instructions a lot faster due to the use of electrical device.

Furthermore, unlike all the earlier machines like the ENIAC or Karl Zuse’s machines, which were developed for military purposes and basically for killing people, EDSAC has always been regarded as a tool for the solution of problems rather than just an engineering achievement because it enabled people to concentrate on scientific problems and do research.

Moreover, it was the first proper computer, with a proper programming language that allowed people to write general-purpose programs on. EDSAC had the first assembly language and was the direct precursor of every modern programming language and arguably the start of the global software industry.