Tomáš Petříček, 204 (2nd floor)
petricek@d3s.mff.cuni.cz
@tomasp.net
https://tomasp.net




Three levels
Intuitions
Formalisms
Implementation
Concepts exist at
all three levels
When one changes
others adapt




Electromechanical general purpose computer
Reads instructions from a punched tape
Synchronized by 15m rotating drive shaft



Routine tapes
Usually endless loops of instructions that transfer control at the end
"The solution of an equation in general requires reference to tables of functions, trigonometric, logarithmic, etc."


Principal bottleneck is the planning of the computation [...] Ways of shortening this process, and of systemizing it, so that a part of the work can be done by the technically trained personnel or by machines, are much desired. The present report is an attack on this problem from the standpoint of composition of computing schedules [...] This problem is here attacked theoretically by using techniques similar to those used in some phases of mathematical logic.
Prefigures many later ideas, but not modern terms

EDVAC (1949)
Mauchly, Eckert, von Neumann, First Draft 1945

ACE (1950)
Automatic Computing Engine, designed by Turing in 1945


[W]hereas von Neumann set out to design an automatic calculator, Turing was more concerned to produce a practical version of the universal machine.
The ACE (...) maintained a strict distinction between memory and control reminiscent of the universal machine, whereas the EDVAC complicated this (..) with special-purpose units.
(from Priestley's Science of Operations)

When we wish to start on a subsidiary operation we need only make a note of where we left off the major operation and then apply the first instruction of the subsidiary.
When the subsidiary is over we look up the note
and continue with the major operation.
the burying being done through a standard instruction table BURY, and the disinterring by the table UNBURY.


Started while ENIAC was still programmed by plugging cables
Later parts after ENIAC reprogramming & Manchester Baby
Envisions a lot of later programming

... even fairly elementary processes should be made a matter of subroutine. (...) those of any complexity presumably ought to be in a library - that is, a set of magnetic tapes
We call the coded sequence of a problem a routine, and one which is formed with the purpose of possible substitution into other routines, a subroutine. (...) properly organized automatic, high speed establishment will include an extensive collection of such subroutines (...) i.e. a "library"



Second edition report (1951)
... a mathematical calculation usually requires an extended sequence of orders. It is often convenient to break up this sequence of orders into self-contained groups of orders called subroutines.
Rewriting addresses
The written and punched form is called the external form, and the form inside the machine the internal form.

Entered immediately after the execution of the order coming before it (...) control passes to the order immediately following it.
Placed anywhere in the store, entered by a jump order and left by another jump order
Order code different from the basic order code of the machine. Extracted one by one, by the interpretive subroutine, which examines them, and carries out the appropriate operations.




Recursive functions theory of Kleene
Left Polish notation
Before FOTRAN, but largely forgotten

SUB DEF) called using CALL statementFUNCTION)
=expr), call is expressionPROCEDURE) call is a statement"The mathematical concept of a function as a mapping from domain to range ... which absolutely excludes any kind of so-called side effects."



≡ uses its free variables directly (by reference), one defined with = has them evaluated ... (by value).where clauses)
Procedures in ALGOL are second class (...) we can write:
(if x > 1 then a else b) + 6We cannot correctly write:
(if x > 1 then sin else cos)(x)nor can we write a type procedure (ALGOL’s nearest approach to a function) with a result which is itself a procedure.




