Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: David Teller <David.Teller@ens-lyon.org>
To: caml-list@inria.fr
Subject: Re: [Caml-list] Re: Concurrent and Distributed Programming in Ocaml
Date: Fri, 16 Dec 2005 13:28:27 +0000	[thread overview]
Message-ID: <1134739708.11220.24.camel@calaf.rn.informatics.scitech.susx.ac.uk> (raw)
In-Reply-To: <dnucib$sv8$1@sea.gmane.org>

While this module is absolutely great, it suffers from OCaml's
limitation that multi-threaded code runs only one one processor, even if
several are available.

For concurrency, I would suggest taking a look at Acute, but that's
quite low-level, when compared to JoCaml. Basically, the communication
primitives are similar to a somewhat lower-level version of the Event
module. I don't know whether there is a native code compiler, though.

Cheers,
 David

On Fri, 2005-12-16 at 13:40 +0100, Vincenzo Ciancia wrote:
> Alexsandro Soares wrote:
> 
> > Our first try used the
> > primitives provided in modules Mutex and Condition to
> > do syncronization between process and threads [...] we 
> > would like to use higher level constructs to work with 
> > concurrent and distributed programming. What are the 
> > options to do this in OCaml?
> 
> I would recommend trying the Event module which features channels and
> events, which in turn are an abstraction which allows to build more complex
> events from simpler ones before "synchronizing" on the resulting event.
> 
> For example, "receive a" is the event that, when you synchronize to it,
> waits for a value to be sent on channel "a", and returns the value, and
> "choose [receive a,receive b]" is the event that, when you synchronize to
> it, waits for a value to be sent on either "a" or "b" and returns the value
> - in this case a and b must have the same value type.
> 
> http://caml.inria.fr/pub/docs/manual-ocaml/libref/Event.html
> 
> Bye
> 
> Vincenzo
> 
-- 
Read, write and publish e-books,
 Free software, Open standards, Open source,
  The OpenBerg project -- http://www.openberg.org


      reply	other threads:[~2005-12-16 13:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-12-16 11:51 Alexsandro Soares
2005-12-16 12:40 ` Vincenzo Ciancia
2005-12-16 13:28   ` David Teller [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1134739708.11220.24.camel@calaf.rn.informatics.scitech.susx.ac.uk \
    --to=david.teller@ens-lyon.org \
    --cc=caml-list@inria.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox