OCaml 4.11.0, third alpha release with RISC-V backend

A new alpha version of OCaml 4.11.0 has been published.

Exceptionally, this third alpha release integrates a new exciting feature: a native-code backend for RISC-V.
Since this new backend cannot affect negatively other architecture, the feature
has been backported to the 4.11 branch.

Beyond this important change, the full change list compared to the second alpha
is rather small:

  • [new feature] 9440: Add RISC-V RV64G native-code backend.
    (Nicolás Ojeda Bär, review by Xavier Leroy and Gabriel Scherer)

  • [additional fixes] 8920, 9238, 9239, 9254, 9458: New API for statistical memory profiling
    in Memprof.Gc. The new version does no longer use ephemerons and allows
    registering callbacks for promotion and deallocation of memory
    blocks.
    The new API no longer gives the block tags to the allocation callback.

  • 7520, 9547: Odd behaviour of refutation cases with polymorphic variants
    (Jacques Garrigue, report by Leo White, reviews by Gabriel Scherer and Leo)

  • 7741, 9645: Failure to report escaping type variable
    (Jacques Garrigue, report by Gabriel Radanne, review by Gabriel Scherer)

  • 9623, 9642: fix typing environments in Typedecl.transl_with_constraint
    (Gabriel Scherer, review by Jacques Garrigue and Leo White,
    report by Hugo Heuzard)

  • 9610: manual, C FFI: naked pointers are deprecated, detail the
    forward-compatible options for handling out-of-heap pointers.
    (Xavier Leroy, review by Mark Shinwell, David Allsopp and Florian Angeletti)

  • 9618: clarify the Format documentation on the margin and maximum indentation
    limit
    (Florian Angeletti, review by Josh Berdine)

We are expecting this third alpha release to be the last alpha release.

The compiler can be installed as an OPAM switch with one of the following commands

opam switch create ocaml-variants.4.11.0+alpha3 --repositories=default,beta=git+https://github.com/ocaml/ocaml-beta-repository.git

or

opam switch create ocaml-variants.4.11.0+alpha3+<VARIANT> --repositories=default,beta=git+https://github.com/ocaml/ocaml-beta-repository.git

where <VARIANT> is replaced with one of these: afl, flambda, fp, fp+flambda

The source code for the alpha is also available at these addresses:

https://github.com/ocaml/ocaml/archive/4.11.0+alpha3.tar.gz
https://caml.inria.fr/pub/distrib/ocaml-4.11/ocaml-4.11.0+alpha3.tar.gz

If you find any bugs, please report them here:
https://github.com/ocaml/ocaml/issues

4 Likes

Would be nice to have the -O3 by default in all flambda switches too: https://github.com/ocaml/opam-repository/pull/16619