[erlang-questions] Tilera 64-core chip - let's help them help us!
Thu Sep 6 16:00:48 CEST 2007
On 9/6/07, Hugh Perkins <hughperkins@REDACTED> wrote:
> > One key point for Berkeley is "To maximize programmer productivity,
> > programming models should be independent of the number of
> > processors."
> What are good resources I can read to find out how Erlang programs get
> split across different processors?
Erlang programs don't get split across different processors by automatic.
You use the builtin very lightweight Erlang processes to solve your
use message passing between the processes. This the typical way to structure an
Erlang program which is used regardless of how many processors or cores
When you run on an SMP system with separate CPU's or with a multicore CPU
the Erlang VM can use many schedulers running as OS threads to achieve
true parallell execution. Typically you use 2 schedulers on a dual
core system, 4
on a quad core system and so on.
Each of the scheduler threads will pick Erlang-processes from a common
run-queue and execute them. A typical system can have thousands of
Erlang processes running simultaneously. A WEB-server implemented in
Erlang will typically create one or sometimes several Erlang processes
This approach will mostly scale well with the number of
processors/cores in an SMP system.
> What about things like maps? To what extent can/will Erlang map them
> across different processors?
If you implement a parallell map function your self, which is really easy
you can take advantage of many processors.
As said Earlier nothing will be parallell by automatic. The nice
thing with Erlang
is that it is so easy and natural to implement explicit parallellism.
/Kenneth (Erlang/OTP team at Ericsson)
More information about the erlang-questions