caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Erik Rigtorp <erik@rigtorp.com>
To: Gerd Stolpmann <gerd@gerd-stolpmann.de>
Cc: caml-list <caml-list@yquem.inria.fr>
Subject: Re: [Caml-list] OCaml is broken
Date: Mon, 21 Dec 2009 20:55:26 +0100	[thread overview]
Message-ID: <a57051ba0912211155p4405c4c1v5d46d863856253d1@mail.gmail.com> (raw)
In-Reply-To: <1261325906.6545.39.camel@flake.lan.gerd-stolpmann.de>

On Sun, Dec 20, 2009 at 17:18, Gerd Stolpmann <gerd@gerd-stolpmann.de> wrote:
> As you mention order books and soft-realtime, I guess your main concern
> are minimized latencies. Well, you need then a style of parallelism that
> focuses on a certain processing path for a single data item, and where
> the latency is minimized by using several cores. I think ocaml is
> unsuited for this type of task, but please don't call ocaml "broken"

It is actually perfectly suitable for this, as long as you can run
multiple runtimes and share data via low latency message passing. This
is kind of how Erlang does it, with a separate heap for each
lightweight thread (called process in Erlang).

> because of this. Other types of parallelism can be well supported,
> especially when you can accept multi-processing, and when you focus on
> larger processing paths and partitioned data sets.

I agree, but fork() and pipe() has problems.

1. Latency is high ~10µs when tuned on Solaris, substantially higher
>100µs on Linux.
2. Runtimes don't share memory so data has to be copied. This is fine
for small datasets or streaming data, like passing order book updates
around.

Even if I want to process a dataset and partition it and sends the
work to multiple processes there is no framework in OCaml for me to
use.

Erik


  reply	other threads:[~2009-12-21 19:55 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-19  9:30 Erik Rigtorp
2009-12-19  9:42 ` [Caml-list] " Stéphane Glondu
2009-12-19 10:38 ` Sylvain Le Gall
2009-12-19 18:22 ` [Caml-list] " Thomas Fischbacher
2009-12-20 16:18 ` Gerd Stolpmann
2009-12-21 19:55   ` Erik Rigtorp [this message]
2009-12-21 21:21     ` Sylvain Le Gall
2009-12-29 12:00       ` [Caml-list] " Richard Jones
2010-01-01 16:25 ` [Caml-list] " Florian Weimer

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=a57051ba0912211155p4405c4c1v5d46d863856253d1@mail.gmail.com \
    --to=erik@rigtorp.com \
    --cc=caml-list@yquem.inria.fr \
    --cc=gerd@gerd-stolpmann.de \
    /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;
as well as URLs for NNTP newsgroup(s).