[Caml-list] Attn: Development Editor, Latest OCaml Weekly News

Alan Schmitt
2020-03-03T08:00:22Z

[-- Attachment #1: Type: text/plain, Size: 12736 bytes --]

Here is the latest OCaml Weekly News, for the week of February 25 to
March 03, 2020.

Table of Contents
─────────────────

OCaml 4.10 released
Summary of the Dune retreat 2020
Multicore OCaml: Feb 2020 update
Oplot 0.50
soupault: a static website generator based on HTML rewriting
Old CWN

OCaml 4.10 released
═══════════════════

Archive: <https://discuss.ocaml.org/t/ocaml-4-10-released/5194/4>

Contnuing this thread, Anil Madhavapeddy said
─────────────────────────────────────────────

Indeed, many thanks to everyone who leapt in to make 4.10 ready in
opam in such record time! Just a note that the CI Docker images are
now also rebuilt for x86_64, arm32/64 and ppc64le to reflect the 4.10
release, so feel free to start using
them. <https://hub.docker.com/r/ocaml/opam2/tags>

Summary of the Dune retreat 2020
════════════════════════════════

Archive:
<https://discuss.ocaml.org/t/summary-of-the-dune-retreat-2020/5224/1>

Jérémie Dimino announced
────────────────────────

We recently organised the second Dune retreat. If you'd like to see
what is happening in the Dune world at the moment, please find a
summary of what we discussed and work on in this blog post!

<https://dune.build/blog/dune-retreat-2020/>

Multicore OCaml: Feb 2020 update
════════════════════════════════

Archive:
<https://discuss.ocaml.org/t/multicore-ocaml-feb-2020-update/5227/1>

Anil Madhavapeddy announced
───────────────────────────

Welcome to the February 2020 news update from the Multicore OCaml
team, spread across the UK, India, France and Switzerland! This
follows on from [last month's] update, and has been put together by
@shakthimaan and @kayceesrk.

The [release of OCaml 4.10.0] has successfully pushed out some
prerequisite features into the upstream compiler. Our work in
February has focussed on getting the multicore OCaml branch "feature
complete" with respect to the complete OCaml language, and doing
extensive benchmarking and stress testing to test our two minor heap
implementations.

To this end, a number of significant patches have been merged into the
[Multicore OCaml trees] that essentially provide complete coverage of
the language features. We encourage you to test the same for
regressions and provide any improvements or report shortcomings to
us. There are ongoing OCaml PRs and issues that are also under review,
and we hope to complete those for the 4.11 release cycle. A new set of
parallel benchmarks have been added to our [Sandmark benchmarking
suite] (live instance [here]), including enhancements to the build
setup.

[last month's]
<https://discuss.ocaml.org/t/multicore-ocaml-january-2020-update/5090>

[release of OCaml 4.10.0]
<https://discuss.ocaml.org/t/ocaml-4-10-released/5194>

[Multicore OCaml trees]
<https://github.com/ocaml-multicore/ocaml-multicore>

[Sandmark benchmarking suite] <https://github.com/ocaml-bench/sandmark>

[here] <http://bench2.ocamllabs.io>

Multicore OCaml
╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌

◊ Completed

The following PRs have been merged into Multicore OCaml:

• [ocaml-multicore/ocaml-multicore#281] Introduce `Forcing_tag' to fix
concurrency bug with lazy values

A `Forcing_tag' is used to implement lazy values to handle a
concurrency bug. It behaves like a locked bit, and any concurrent
access by a mutator will raise an exception on that domain.

• [ocaml-multicore/ocaml-multicore#282] Safepoints

A preliminary version of safe points has been merged into the
Multicore OCaml trees. [ocaml-multicore/ocaml-multicore#187] also
contains more discussion and background about how coverage can be
improved in future PRs.

• [ocaml-multicore/ocaml-multicore#285] Introduce an 'opportunistic'
major collection slice

An "opportunistic work credit" is implemented in this PR which forms
a basis for doing mark and sweep work while waiting to synchronise
with other domains.

• [ocaml-multicore/ocaml-multicore#286] Do fflush and variable args in
caml_gc_log

The caml_gc_log() function has been updated to ensure that `fflush'
is invoked only when GC logging is enabled.

• [ocaml-multicore/ocaml-multicore#287] Increase EVENT_BUF_SIZE

During debugging with event trace data it is useful to reduce the
buffer flush times, and hence the `EVENT_BUF_SIZE' has now been
increased.

• [ocaml-multicore/ocaml-multicore#288] Write barrier optimization

This PR closes the regression for the `chameneos_redux_lwt'
benchmarking in Sandmark by using `intnat' to avoid sign extensions
and cleans up `write_barrier' to improve overall performance.

• [ocaml-multicore/ocaml-multicore#290] Unify sweep budget to be in
word size

The PR updates the sweep work units to all be in word size. This is
to handle the differences between the budget for setup, sweep and
for large allocations in blocks.

[ocaml-multicore/ocaml-multicore#281]
<https://github.com/ocaml-multicore/ocaml-multicore/pull/281>

[ocaml-multicore/ocaml-multicore#282]
<https://github.com/ocaml-multicore/ocaml-multicore/pull/282>

[ocaml-multicore/ocaml-multicore#187]
<https://github.com/ocaml-multicore/ocaml-multicore/issues/187>

[ocaml-multicore/ocaml-multicore#285]
<https://github.com/ocaml-multicore/ocaml-multicore/pull/285>

[ocaml-multicore/ocaml-multicore#286]
<https://github.com/ocaml-multicore/ocaml-multicore/pull/286>

[ocaml-multicore/ocaml-multicore#287]
<https://github.com/ocaml-multicore/ocaml-multicore/pull/287>

[ocaml-multicore/ocaml-multicore#288]
<https://github.com/ocaml-multicore/ocaml-multicore/pull/288>

[ocaml-multicore/ocaml-multicore#290]
<https://github.com/ocaml-multicore/ocaml-multicore/pull/290>

◊ Ongoing

• A lot of work is ongoing for the implementation of a synchronised
minor garbage collector for Multicore OCaml, including benchmarking
for the stop-the-world (stw) branch. We will publish the results of
this in a future update, as we are assembling a currently
comprehensive evaluation of the runtime against the mainstream
runtime.

Benchmarking
╌╌╌╌╌╌╌╌╌╌╌╌

[Sandmark] now has support to run parallel benchmarks. We can also now
about GC latency measurements for both stock OCaml and Multicore OCaml
compiler.

• [ocaml-bench/sandmark#73] More parallel benchmarks

A number of parallel benchmarks such as N-body, Quick Sort and
matrix multiplication have now been added to Sandmark!

• [ocaml-bench/sandmark#76] Promote packages. Unbreak CI.

The Continuous Integration build can now execute after updating and
promoting packages in Sandmark.

• [ocaml-bench/sandmark#78] Add support for collecting information
about GC pausetimes on trunk

The PR now helps process the runtime log and produces a `.bench'
file that captures the GC pause times. This works on both stock
OCaml and in Multicore OCaml.

• [ocaml-bench/sandmark#86] Read and write Irmin benchmark

A test for measuring Irmin's merge capabilities with Git as its
filesystem is being tested with different read and write rates.

• A number of other parallel benchmarks like Merge sort,
Floyd-Warshall matrix, prime number generation, parallel map, filter
et. al. have been added to Sandmark.

[Sandmark] <http://bench2.ocamllabs.io/>

[ocaml-bench/sandmark#73]
<https://github.com/ocaml-bench/sandmark/pull/73>

[ocaml-bench/sandmark#76]
<https://github.com/ocaml-bench/sandmark/pull/76>

[ocaml-bench/sandmark#78]
<https://github.com/ocaml-bench/sandmark/pull/78>

[ocaml-bench/sandmark#86]
<https://github.com/ocaml-bench/sandmark/pull/86>

Documentation
╌╌╌╌╌╌╌╌╌╌╌╌╌

• Examples using domainslib and modifying Domains are currently being
worked upon for a chapter on Parallel Programming for Multicore
OCaml. We will release an early draft to the community for your
feedback.

OCaml
╌╌╌╌╌

One PR opened to OCaml this month, which fixes up the marshalling
scheme to be multicore compatible. The complete set of [upstream
multicore prerequisites] are labelled in the compiler issue tracker.

• [ocaml/ocaml#9293] Use addrmap hash table for marshaling

The hash table (addrmap) implementation from Multicore OCaml has
been ported to upstream OCaml to avoid using GC mark bits to
represent visitedness.

[upstream multicore prerequisites]
<https://github.com/ocaml/ocaml/labels/multicore-prerequisite>

[ocaml/ocaml#9293] <https://github.com/ocaml/ocaml/pull/9293>

Acronyms
╌╌╌╌╌╌╌╌

• CTF: Common Trace Format
• CI: Continuous Integration
• GC: Garbage Collector
• PR: Pull Request

As always, many thanks to our fellow OCaml developers and users who
have reviewed our code, reported bugs or otherwise assisted this
month.

Oplot 0.50
══════════

Archive: <https://discuss.ocaml.org/t/ann-oplot-0-50/5235/1>

sanette announced
─────────────────

I'm happy to annouce the revival of the `oplot' library.

If you ever wanted to quickly draw the graph of an intriguing
mathematical function, animate it by varying a parameter, or explore a
3D surface, without leaving your favorite programming language, then
`oplot' is for you.

If you're familiar with LaTeX and want to produce nice mathematical
graphics decorated with LaTeX formulas, that you can view onscreen,
export to images or vector graphics (pdf, eps) then `oplot' is even
more for you!

• Installation: `opam install oplot'
• documentation:
<https://sanette.github.io/oplot/oplot/Oplot/index.html>
• source code, issues, etc: <https://github.com/sanette/oplot>

Drawing is hardware accelerated (opengl) thanks to the venerable
`ocamlsdl' and `lablgl' libraries. I'm glad they still work perfectly.

Happy plotting.

soupault: a static website generator based on HTML rewriting
════════════════════════════════════════════════════════════

Archive:
<https://discuss.ocaml.org/t/ann-soupault-a-static-website-generator-based-on-html-rewriting/4126/12>

Daniil Baturin announced
────────────────────────

[1.9.0] release is now available.

• `--index-only' option that makes soupault dump the site metadata to
JSON and stop at that
• Metadata extraction and index generation can now be limited to
specific pages/section/path regexes, just like widgets
• The `preprocess_element' widget now supports a list of selectors,
e.g. `selector = ["code", "pre code"]'.
• Plugin API now has functions for running external programs, and some
more element tree access functions.
• CSS selector parse errors are now handled gracefully ([lambdasoup
PR#31]).
• The `title' widget now correctly removes HTML tags from the supposed
title string and doesn't add extra whitespace (fixes by [Thomas
Letan]).

[1.9.0] <https://soupault.neocities.org/blog/soupault-1.9.0-release/>

[lambdasoup PR#31] <https://github.com/aantron/lambdasoup/pull/31>

[Thomas Letan] <https://soap.coffee/~lthms/>

Old CWN
═══════

If you happen to miss a CWN, you can [send me a message] and I'll mail
it to you, or go take a look at [the archive] or the [RSS feed of the
archives].

If you also wish to receive it every week by mail, you may subscribe
[online].

[Alan Schmitt]

[send me a message] <mailto:alan.schmitt@polytechnique.org>

[the archive] <http://alan.petitepomme.net/cwn/>

[RSS feed of the archives] <http://alan.petitepomme.net/cwn/cwn.rss>

[online] <http://lists.idyll.org/listinfo/caml-news-weekly/>

[Alan Schmitt] <http://alan.petitepomme.net/>

[-- Attachment #2: Type: text/html, Size: 25154 bytes --]