Experimental Archaeology in Digital Computing
Hacking 36 Bits at a Time

Björn Victor

Uppsala University (1985-)/Update (1983-)

Background: hacker, sysadmin, formal methods to get it right

Experimental Archaeology?

What do the archaeological artifacts (e.g. stone chips, bronze fragments) mean? What were they used for, and how?

To find out: experimental archaeology:
reconstruct and recreate conditions, tools, equipment etc to test, evaluate and explicate method, technique, assumption, hypothesis and theories.
i.e: to see if and how it worked.

Example: Heyerdahl's Kon-Tiki and Ra travels (S. America-Polynesia, Egypt-S.Am).

What has this got to do with NUCCC?

[any material that should appear in print but not on the slide]

...in Digital Computing

DEC: Digital Equipment Corporation, Maynard, Massachusetts.

PDP-11: unix origin, continued on VAX

36 Bits at a Time

First DEC 36-bit machine: PDP-6 (1964), followed by the PDP-10 in 1967.

PDP-10: Architectural basics

Instruction format

Instruction format by example:

MOVEI 2,@FOO(3)
1. Calculate effective address
FOO: 18-bit (right halfword)
(3): index by contents of register 3
@: indirect addressing - "recurse" at that address (using indexing and indirection, until not indirect)
2. then execute instruction MOVEI
move Immediate (use the effective address, not contents) to register 2

Logically grouped instruction set

Move a word
MOV[ESNM]{I,M,S}? register, address
  • [ESNM] E: standard; S: swapped; N: negate; M: magnitude
  • {I,M,S} I: immediate; M: reg to memory; S: to self
Halfword move
H[RL][RL]{Z,O,E}?{I,M,S}? register, address
  • {Right,Left}-to-{Right,Left} and {Zero,Ones,Extend} to other half
Logical test and modification
T[RLDS][NZCO]{E,A,N}? register, address
  • Test {Right,Left,Direct,Swapped} mask, {No,Zeros,Complement,Ones} modification, and skip if bits {Equal,Always,Not equal} to zero
Ex: MOVS 2,FOO - swaps content of FOO and moves to reg 2
Ex: HRLZM 2,BAR - moves RH(2) to LH(BAR), zeroes RH(BAR)
Ex: TLCE 2,700 - test if LH(2) has 700 bits set, complement them, and skip if zero

Other instructions

Some more instruction examples:

Experiments: operating systems

Historical perspective

Archaeological perspective

TOPS-20

Features:

Misfeatures(?)

good timesharing: ~60 lisp users
powerful macros: subroutines with args, local variables, ...

TOPS-20: Interactive experiments

It's safe to try this at home!

show completion, noise, abbrev, ?

ITS (from the New Hacker's Dictionary)

  1. Incompatible Time-sharing System, an influential though highly idiosyncratic operating system written for PDP-6s and PDP-10s at MIT and long used at the MIT AI Lab.
    ...
    ITS pioneered many important innovations, including transparent file sharing between machines and terminal-independent I/O....
  2. A mythical image of operating-system perfection worshiped by a bizarre, fervent retro-cult of old-time hackers and ex-users....
    ITS worshipers manage somehow to continue believing that an OS maintained by assembly-language hand-hacking that supported only monocase 6-character filenames in one directory per account remains superior to today's state of commercial art...

ITS: Incompatible Timesharing System

Developed at MIT: 196x - 1982/1990. Origin of EMACS.

ITS: Interactive experiments

Try it!

See http://victor.se/bjorn/its/luser.php for cheat codes.

Emulating the PDP-10

Questions when emulating old systems:

"Experimental archaeology" needed -
try and see what works, and/or if it works.

The KLH10 emulator

KLH10: The best available PDP-10 emulator (cf. e.g. simh, kx10).

Archaeological experience

Some of my experience as experimental archaeologist:

and lots of fun!

Conclusion

Some random conclusions:

Play at home: check out http://www.aracnet.com/~healyzh/pdp10emu.html, http://victor.se/bjorn/its