[m-users.] Parallel execution in Mercury?
Paul Bone
paul at bone.id.au
Sat Jan 12 00:30:34 AEDT 2019
On Fri, Jan 11, 2019 at 01:43:56PM +0100, Matthias Güdemann wrote:
> Hi Volker,
>
> > There are a large amount of papers on parallelism on http://mercurylang.org/
> > documentation/papers.html, but I couldn't find anything in the Language
> > Reference Manual, User's Guide, Library Reference Manual and the FAQ.
>
> I wrote an article about parallelism in Mercury a while ago
> http://guedemann.org/articles/Mar-17-2015.html
>
> Maybe that is useful for you. In short, you need a parallel grade and
> you use the `&` conjunction.
>
> There is also the `thread` module in the library, but I haven't used this yet.
>
> search for `parallel` here:
>
> https://www.mercurylang.org/information/doc-latest/mercury_user_guide/Optional-features-compilation-model-options.html
In addition to these checkout some of the examples.
In the source tarball and git repository they're under benchmarks/progs/
There are a few examples that work with parallelism, some are designed to
work with the still experimental auto-parallelism. However others:
+ various versions of icfp2000 (a raytracer)
+ mandelbrot
These were known to work last time I tried them.
Mandelbrot might be the best to look at first, depending on command line
arguments it attempts to run in parallel in various ways (for comparing
them).
--
Paul Bone
http://paul.bone.id.au
More information about the users
mailing list