Occam Language

A minimalist language, named after WilliamOfOccam, a medieval monk/philosopher who used OccamsRazor to clear the logical underbrush. Occam's Razor: do not multiply entities unnecessarily. See http://www.afm.sbu.ac.uk/occam/, http://www.museophile.sbu.ac.uk/pub/jpb/toulouse92.pdf

Occam the language is a HighLevelLanguage used for programming transputers - a transputer is a chip with CPU, IO, and RAM. It is a structured language with parallelism designed for a multiprocessor system. InterProcessCommunication is done using the same model as CarHoare's CommunicatingSequentialProcesses.

Its main syntactic quirk is that IndentationEqualsGrouping, i.e. blocks of code are indicated by indenting their contents rather than by using a lexeme at the beginning and end. This works because you get a special editor as well as compiler. The editor allows the contents of blocks to be hidden or visible. It is like using a word processor in outline mode.

The main semantic quirk is that you write and compile an Occam program without stating how many processors you have, or how they are connected. At load time the programs are distributed over whatever network you have. If two parallel processes are running on the same chip, or on different chips.... the program works the same (except for speed...).

This is possible because of the explicit support for parallel execution in the language - starting/synchronising threads and so on is very straightforward (and very lightweight on the transputer). It takes a while to get your head around the model, but once you do it's pretty cool.

Can somebody point to an internetworked version of Occam (if such a compiler exists), that distributes the workload on different Internet servers? -- FridemarPache

The ConicLanguage? and runtime system from Imperial College, and later systems Rex, Regis and Regent, all used a similar model to CSP (and Occam), except they use a separate ArchitectureDescriptionLanguage for describing the architecture of a system in terms of instantiated components and their interconnections. Conic was based on Pascal, with extensions for communication through typed channels and an extensive run-time system for deployment and run-time monitoring and reconfiguration. The compiler generated code for Sparcs, ix86 PCs and 68000-based embedded targets. Tonic was an internal version written for the transputer and was significantly faster than Occam. Conic was also implemented in Smalltalk. Rex, Regis and Regent were implemented as libraries for C, C++ and Java, respectively, and extended the concepts of Conic with user-definable interaction protocols (rather than only using CSP's synchronous channels) and transport protocols that can be selected at run-time. These later systems use a separate configuration language, Darwin, that is independent of the language used to implement components. Darwin is also used to structure formal models of a system so that a design can be checked for deadlock, livelock etc.


It is difficult to imagine a compiled language "significantly faster" than occam, unless it is transputer's assembler.

-- Bakhteiarov
Various people at the UniversityOfKent? and elsewhere are working on OccamPi.

EditText of this page (last edited May 28, 2014) or FindPage with title or text search