roger peppe wrote:
> threads on inmos transputers didn't share memory. the threads
> were scheduled by the processor itself (zero context-switch time,
> which was nice), but could just as easily be on separate processors

occam processes (aka threads) can share state but the language
enforces read-only access (unless you turn off that checking
which you often needed to given limitations in its implementation).
State sharing, of course, doesn't work when processes are mapped
to different processors (although the machine I used to use had a
large chunk of memory shared between the CPUs where we kept data
we didn't want to move around).

The transputer's context switch did have a small cost but it was
fast for its time.  Three registers written to the on-chip RAM.
Given the nature of occam, and the transputer being an engine
for running occam, efficient support for lots of processes is
a must.  These days people seem to be getting all excited about
it again.

> i don't *think* you could pass shared references around, but
> it was a long time ago.

It was possible.  But like yourself its been a long time since
I did all this (twenty years) and the details are sketchy but
we definitely passed addresses down channels and did shared
accesses (no pesky MMU to get in the way :)

Reply via email to