caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Markus Mottl <mottl@miss.wu-wien.ac.at>
To: Gerd Stolpmann <gerd@gerd-stolpmann.de>
Cc: Miles Egan <miles@caddr.com>, OCAML <caml-list@inria.fr>
Subject: Re: features of PCRE-OCaml
Date: Sun, 10 Dec 2000 01:32:05 +0100	[thread overview]
Message-ID: <20001210013205.B8110@miss.wu-wien.ac.at> (raw)
In-Reply-To: <0012091437390B.00625@ice>; from gerd@gerd-stolpmann.de on Sat, Dec 09, 2000 at 14:12:13 +0100

Gerd Stolpmann schrieb am Saturday, den 09. December 2000:
> I would say it depends on the problem size. For example, when searching in a
> long text it is definitely worth-while to release the masterlock.
[snip]
> I think it is worth an experiment.

I have first given it a thought experiment and came to the conclusion
that it does not seem to be a good idea to have a default with possibly
superfluous overheads. If somebody really wants to exploit multi-processor
machines with OCaml, it is probably best to have additional functions
(or even better: a different module) that are tailored for parallel
computation.

This moves the responsibility to the programmer, who usually knows
best whether parallelism for specific uses is worth the overhead. If
somebody wants to try this out (placing those fancy master lock functions
around various code parts in the C-interface (pcre-OCaml/pcre_intf.c)
and measure the performance difference), just fetch the current sources
from the CVS-repository on Sourceforge:

  http://sourceforge.net/cvs/?group_id=15427

It should be very straightforward to add a "parallel" version, but the
tuning + experimentation may require some work. Maybe two submodules
in the "Pcre"-module would be nice: something like "Pcre.Normal" and
"Pcre.Parallel", both of which have the same interface and can even
share values so that one could choose at runtime which version should
execute a regular expression (or compile one, etc.).

I'd be happy to let you integrate a solution for parallel pattern
matching. I don't need this feature right now, but I'd be interested in
reports on executing regexps of PCRE-OCaml in parallel on a 32 processor
machine... ;)

- Markus Mottl

-- 
Markus Mottl, mottl@miss.wu-wien.ac.at, http://miss.wu-wien.ac.at/~mottl



      reply	other threads:[~2000-12-11 17:33 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-12-06  0:51 Markus Mottl
2000-12-07 16:01 ` John Max Skaller
2000-12-07 16:32   ` Markus Mottl
2000-12-07 17:08     ` John Max Skaller
2000-12-08  0:03       ` Markus Mottl
2000-12-08 17:52         ` John Max Skaller
2000-12-08  9:19       ` Alain Frisch
2000-12-08 18:11         ` John Max Skaller
2000-12-08 19:48           ` Alain Frisch
2000-12-09 17:07             ` John Max Skaller
2000-12-14 17:35   ` unicode support Nickolay Semyonov
2000-12-07 20:17 ` features of PCRE-OCaml Miles Egan
2000-12-08 12:30   ` Gerd Stolpmann
2000-12-08 15:05     ` Markus Mottl
2000-12-08 15:40       ` Gerd Stolpmann
2000-12-09  3:03         ` Markus Mottl
2000-12-09 13:12           ` Gerd Stolpmann
2000-12-10  0:32             ` Markus Mottl [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=20001210013205.B8110@miss.wu-wien.ac.at \
    --to=mottl@miss.wu-wien.ac.at \
    --cc=caml-list@inria.fr \
    --cc=gerd@gerd-stolpmann.de \
    --cc=miles@caddr.com \
    /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).