OCaml 32bits longval

Date: 2011-05-06
Category: Tooling



You will need OCaml 3.11.2 installed on a i686 linux computer. The archive contains:

  • libcamlrun-linux-i686.a
  • ocamlrun-linux-i686
  • Makefile
  • README

The Makefile has two targets:

  • sudo make install will save /usr/bin/ocamlrun and /usr/lib/ocaml/libcamlrun.a in the current directory and replace them with the longval binaries.
  • sudo make restore will restore the saved files.

If your install directories are not the default ones, you should modify the Makefile. After installing, you can test it with the standard OCaml top-level:

Objective Caml version 3.11.2


# let s = ref “”;;
val s : string ref = {contents = “”}

# s := String.create 20_000_000;;
– : unit = ()

Now you can enjoy big values in all your strings and arrays in bytecode. You will need to relink all your custom binaries. If you are interested in the native version of the longval compiler, you can contact us.



About OCamlPro:

OCamlPro is a R&D lab founded in 2011, with the mission to help industrial users benefit from state-of-the art programming languages like OCaml and Rust.

We design, create and implement custom ad-hoc software for our clients. We also have a long experience in developing and maintaining open-source tooling for OCaml, such as Opam, TryOCaml, ocp-indent, ocp-index and ocp-browser, and we contribute to the core-development of OCaml, notably with our work on the Flambda optimizer branch.

Another area of expertise is that of Formal Methods, with tools such as our SMT Solver Alt-Ergo (check our Alt-Ergo Users'). We also provide vocational trainings in OCaml and Rust, and we can build courses on formal methods on-demand. Please reach out, we'll be delighted to discuss your challenges: contact@ocamlpro.com or book a quick discussion.