Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OCaml 5.0.0~beta1 release #22245

Merged
merged 2 commits into from
Oct 12, 2022
Merged

Conversation

Octachron
Copy link
Member

The two usual package for the first beta release for OCaml 5.0.

Compared to the alpha release, there are many small internal runtime fixes (in particular in the systhreads library).

At the user level, the interface of the Domain and Effect module has been tweaked to be (hopefully) more forward-compatible:

  • Exceptions related to effects are now defined in the Effecŧ module.
  • The value Domain.recommended_domain_count is no longer a constant and the function Domain.at_each_spawn has been removed.

The standard library should but stable now.
On Windows compiled executables no longer require the winpthread library to be in the user path.

There were also many internal bug fixes as detailed below.

Stdlib update since 5.0.0~alpha1

  • 11309, 11424, 11427, +11545: Add Domain.recommended_domain_count.
    (Christiano Haesbaert, Konstantin Belousov, review by David Allsopp,
    KC Sivaramakrishnan, Gabriel Scherer, Nicolas Ojeda Bar)
  • 11423: Move the effect exceptions to the Effect module

  • 11593: Remove Domain.at_each_spawn

Bug fixes since 5.0.0~alpha1

  • 11303: Ensure that GC is not invoked from bounds check failures
    (Stephen Dolan, review by Sadiq Jaffer and Xavier Leroy)

  • 5299, 4787, 11138, 11272, 11506: To help debugging, Caml_state
    now dynamically checks that the domain lock is held, and fails
    otherwise (with a fatal error at most entry points of the C API, or
    systematically in debug mode). A new variable Caml_state_opt is
    introduced, and is NULL when the domain lock is not held. This
    allows to test from C code if the current thread holds the lock of
    its domain.
    (Guillaume Munch-Maccagnoni, review by Florian Angeletti, Damien
    Doligez, Sadiq Jaffer, Xavier Leroy, and Gabriel Scherer)

  • 11223: The serialization format of custom blocks changed in 4.08,
    but the deserializer would still support the pre-4.08 format. OCaml
    5.x removed support for this old format; provide a clear error message
    in this case.
    (Hugo Heuzard, review by Gabriel Scherer)

  • 11504, 11522: Use static allocation in caml_make_float_vect in
    no-flat-float-array mode, it's more efficient and avoids a a race condition
    (Xavier Leroy, report by Guillaume Munch-Maccagnoni, review by David Allsopp)

  • 11461, 11466: Fix gethostbyaddr for IPv6 arguments and make it domain-safe
    (Olivier Nicole, Nicolás Ojeda Bär, David Allsopp and Xavier Leroy,
    review by the same)

  • 11479: Make Unix.symlink domain-safe on Windows
    (Olivier Nicole, review by Xavier Leroy and David Allsopp)

  • 11294: Switch minimum required autoconf to 2.71.
    (David Allsopp, review by Xavier Leroy)

  • 11370, 11373: Don't pass CFLAGS to flexlink during configure.
    (David Allsopp, report by William Hu, review by Xavier Leroy and
    Sébastien Hinderer)

  • 11487: Thwart FMA test optimization during configure
    (William Hu, review by David Allsopp and Sébastien Hinderer)

  • 11468: Fix regression from 10186 (OCaml 4.13) detecting IPv6 on Windows for
    mingw-w64 i686 port.
    (David Allsopp, review by Xavier Leroy and Sébastien Hinderer)

  • 11482, 11542: Fix random crash in large closure allocation
    (Damien Doligez, report by Thierry Martinez and Vincent Laviron, review by
    Xavier Leroy)

  • 11508, 11509: make Bytes.escaped domain-safe
    (Christiano Haesbaert and Gabriel Scherer,
    review by Xavier Leroy,
    report by Jan Midtgaard and Tom Kelly)

  • 11516, 11524: Fix the deprecated_mutable attribute.
    (Chris Casinghino, review by Nicolás Ojeda Bär and Florian Angeletti)

  • 11576: Fix bug in Bigarray.Genarray.init in the the case of zero-dimensional
    arrays.
    (Nicolás Ojeda Bär, Jeremy Yallop, report by Masayuki Takeda, review by Jeremy
    Yallop and Florian Angeletti)

  • 11587: Prevent integer comparison from being used on pointers
    (Vincent Laviron, review by Gabriel Scherer)

Documentation update since 5.0.0~alpha1

  • 11093: Add tutorials on parallelism features and the relaxed memory model
    (KC Sivaramakrishnan, review by Damien Doligez, Anil Madhavapeddy, Gabriel
    Scherer, Thomas Leonard, Tom Ridge, Xavier Leroy, Luc Maranget, Fabrice
    Buoro, Olivier Nicole, Guillaume Munch-Maccagnoni, Jacques-Henri Jourdan)

"base-threads" {post}
"base-domains" {post}
"base-nnp" {post}
"ocaml-option-bytecode-only" {arch != "arm64" & arch != "x86_64"}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

if we're adding that, shouldn't there be a similar case for ocaml-base-compiler ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That sounds reasonable: to me: the change originated from the 5.0.0+trunk opam package that was updated by @dra27 but I never imported the change to base-compiler package.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a good idea, but it will need the vanilla package to be tweaked. The +options package definitely needs it - I only didn't update the alpha packages in #21510 because of the unnecessary rebuild that would have triggered for existing switches.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we want to tweak the vanilla package now or should we wait for the next beta?

@kit-ty-kate
Copy link
Member

Thanks!

@kit-ty-kate kit-ty-kate merged commit 7791c44 into ocaml:master Oct 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants