Thu Sep 8 00:50:19 CEST 2005
--- Saifi <saifi.k@REDACTED> wrote:
> Couple of queries about Slides -
> Q. [Create more processes than OS supports.]
> Does Erlang process imply threads here ?
> Are the processes (threads) here library managed
> Is there a documentation for the user API
> somewhere ?
At the language level, "logically", Erlang processes
are independent, shared-nothing processes. An
implementation may use green threads, OS threads, or
something else when implementing the language.
(In the current main implementation, green threads are
used inside each node for Erlang processes. A node is
a heavyweight process.)
> Q. [Message Passing is "send and pray"]
> Is it UDP based communication ?
Again, logically, messages are sent from one process
to another. The mechanism for this is up to the
(Some implementations copy most of the message when
sending messages within a node, others don't;
distributed Erlang normally uses TCP/IP between nodes,
but you can write your own bearer.)
> Q. [Things in the world don't share data]
> Doesn't this make the program's inefficient ?
> In C programs we have shared data among various
> threads ?
The answer to this again depends on the
implementation. In the regular Erlang/OTP, some data
are shared, most are not. In other versions, most or
all data are shared. This choice is normally not
visible on the language level.
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
More information about the erlang-questions