Ritchie
incorporated many of the innovative aspects of Multics, including an explicit notion of a process
as a locus of control, a treestructured
file system, a command interpreter as userlevel
program,
simple representation of text files, and generalized access to devices. They excluded others, such
as unified access to memory and to files. At the start, moreover, he and the rest of us deferred
another pioneering (though not original) element of Multics, namely writing almost exclusively in
a higherlevel
language. PL/I, the implementation language of Multics, was not much to our
tastes, but we were also using other languages, including BCPL, and we regretted losing the
advantages of writing programs in a language above the level of assembler, such as ease of writing
and clarity of understanding. At the time we did not put much weight on portability; interest
in this arose later.
Thompson was faced with a hardware environment cramped and spartan even for the time: rm, cat, cp commands) were completed. After this point, the operating system was the DEC PDP7
on which he started in 1968 was a machine with 8K 18bit
words of memory and
no software useful to him. While wanting to use a higherlevel
language, he wrote the original
Unix system in PDP7
assembler. At the start, he did not even program on the PDP7
itself, but
instead used a set of macros for the GEMAP assembler on a GE635
machine. A postprocessor
generated a paper tape readable by the PDP7.
These tapes were carried from the GE machine to the PDP7
for testing until a primitive
Unix kernel, an editor, an assembler, a simple shell (command interpreter), and a few utilities
(like the Unix
selfsupporting:
programs could be written and tested without resort to paper tape, and development
continued on the PDP7
itself.
Thompson’s PDP7
assembler outdid even DEC’s in simplicity; it evaluated expressions with a fixed name thata.out, explains a bit of Unix etymology; it is the possibly needed a system programming language. After a rapidly scuttled and emitted the corresponding bits. There were no libraries, no loader or link editor: the entire
source of a program was presented to the assembler, and the output file
emerged was directly executable. (This name,
output of the assembler. Even after the system gained a linker and a means of specifying another
name explicitly, it was retained as the default executable result of a compilation.)
Not long after Unix first ran on the PDP7,
in 1969, Doug McIlroy created the new system’s
first higherlevel
language: an implementation of McClure’s TMG [McClure 65]. TMG is a language
for writing compilers (more generally, TransMoGrifiers) in a topdown,
recursivedescent
style that combines contextfree
syntax notation with procedural elements. McIlroy and Bob
Morris had used TMG to write the early PL/I compiler for Multics.
Challenged by McIlroy’s feat in reproducing TMG, Thompson decided that Unix
it had not even been named yet
attempt at Fortran, he created instead a language of his own, which he called B. B can be
thought of as C without types; more accurately, it is BCPL squeezed into 8K bytes of memory
and filtered through Thompson’s brain. Its name most probably represents a contraction of
BCPL, though an alternate theory holds that it derives from Bon [Thompson 69], an unrelated
language created by Thompson during the Multics days. Bon in turn was named either after his
wife Bonnie, or (according to an encyclopedia quotation in its manual), after a religion whose rituals
involve the murmuring of magic formulas. Origins: the languages
BCPL was designed by Martin Richards in the mid1960s
while he was visiting MIT, and
was used during the early 1970s for several interesting projects, among them the OS6 operating
system at Oxford [Stoy 72], and parts of the seminal Alto work at Xerox PARC [Thacker 79].
We became familiar with it because the MIT CTSS system [Corbato 62] on which Richards
worked was used for Multics development. The original BCPL compiler was transported both to
Multics and to the GE635
GECOS system by Rudd Canaday and others at Bell Labs [Canaday
69]; during the final throes of Multics’s life at Bell Labs and immediately after, it was the language
of choice among the group of people who would later become involved with Unix.
BCPL, B, and C all fit firmly in the traditional procedural family typified by Fortran and
No comments:
Post a Comment
THE WORLD NEW TECHNOLOGY