# \#runtime

**URL:** https://discuss.ocaml.org/tag/runtime/461.md

[Latest](https://discuss.ocaml.org/latest.md) · [Categories](https://discuss.ocaml.org/categories.md) · [Tags](https://discuss.ocaml.org/tags.md)

---

## [Back from the trenches: a tale of custom runtime events and being faster than faster](https://discuss.ocaml.org/t/back-from-the-trenches-a-tale-of-custom-runtime-events-and-being-faster-than-faster/16892)

<div class="topic-metadata">

**Author:** [@mattiasdrp](https://discuss.ocaml.org/u/mattiasdrp)\
**Replies:** 0\
**Last updated:** [June 30, 2025, 9:57am UTC](https://discuss.ocaml.org/t/back-from-the-trenches-a-tale-of-custom-runtime-events-and-being-faster-than-faster/16892 "2025-06-30T09:57:38Z")

</div>

Last week I decided to see what was possible to do with custom runtime events. I wrote this piece of code: (\*\* Operation to profile \*) let my\_slow\_op res i = res := !res + i; Unix.sleepf 0.001 (\*\* Operation to pro…

---

## [Standalone Ocaml Runtime Package / Source code](https://discuss.ocaml.org/t/standalone-ocaml-runtime-package-source-code/16480)

<div class="topic-metadata">

**Author:** [@ferdv](https://discuss.ocaml.org/u/ferdv)\
**Replies:** 8\
**Last updated:** [April 18, 2025, 7:57pm UTC](https://discuss.ocaml.org/t/standalone-ocaml-runtime-package-source-code/16480 "2025-04-18T19:57:02Z")

</div>

TL;DR Is there a (preferably straightforward way) of installing the OCaml runtime, separately from the compilers and other tools in the base OCaml distribution? Hi all, I’m coming back to OCaml after almost a decade aw…

---

## [OCaml Cycle detection and Garbage Collector](https://discuss.ocaml.org/t/ocaml-cycle-detection-and-garbage-collector/15757)

<div class="topic-metadata">

**Author:** [@KoviRobi](https://discuss.ocaml.org/u/KoviRobi)\
**Replies:** 6\
**Last updated:** [December 14, 2024, 5:53pm UTC](https://discuss.ocaml.org/t/ocaml-cycle-detection-and-garbage-collector/15757 "2024-12-14T17:53:47Z")

</div>

Hi, I was wondering about something, when it comes to cycle detection – if I naively make a search data structure (hash table, tree) with pointers as keys to detect cycles, then presumably that will break with the garba…

---

## [Ensuring errno survives over leave\_blocking\_section until uerror is called](https://discuss.ocaml.org/t/ensuring-errno-survives-over-leave-blocking-section-until-uerror-is-called/15441)

<div class="topic-metadata">

**Author:** [@edwin](https://discuss.ocaml.org/u/edwin)\
**Replies:** 0\
**Last updated:** [October 14, 2024, 10:24pm UTC](https://discuss.ocaml.org/t/ensuring-errno-survives-over-leave-blocking-section-until-uerror-is-called/15441 "2024-10-14T22:24:34Z")

</div>

SummaryI was looking at how errno, leave\_blocking\_section and uerror interact, and although it all seems to work on Linux, I couldn’t find any guarantees that errno would indeed be preserved over leave\_blocking\_section (…

---

## [Effects with Lwt, a dead end for now?](https://discuss.ocaml.org/t/effects-with-lwt-a-dead-end-for-now/15002)

<div class="topic-metadata">

**Author:** [@kentookura](https://discuss.ocaml.org/u/kentookura)\
**Replies:** 7\
**Last updated:** [July 24, 2024, 7:21pm UTC](https://discuss.ocaml.org/t/effects-with-lwt-a-dead-end-for-now/15002 "2024-07-24T19:21:15Z")

</div>

This thread is basically a discussion about this issue: I am trying to integrate irmin into an application that makes heavy use of effects, in particular Algaeff, Asai and Eio. Now, irmin uses lwt and while there is a…

---

## [Lwt program; stack overflows and SIGSEGVs; heap check assetion fail in freelists.c with debug runtime](https://discuss.ocaml.org/t/lwt-program-stack-overflows-and-sigsegvs-heap-check-assetion-fail-in-freelists-c-with-debug-runtime/13725)

<div class="topic-metadata">

**Author:** [@yashrk](https://discuss.ocaml.org/u/yashrk)\
**Replies:** 10\
**Last updated:** [January 18, 2024, 12:30pm UTC](https://discuss.ocaml.org/t/lwt-program-stack-overflows-and-sigsegvs-heap-check-assetion-fail-in-freelists-c-with-debug-runtime/13725 "2024-01-18T12:30:35Z")

</div>

Hi. I have a service compiled with OCaml 4.13.1, with Lwt as an async framework. It crashes in production with a stack overflow or segmentation fault error. Initially it looked like an error in my code: in call graphs an…

---

## [\[WATCH\] OCaml behind the scenes: Exception](https://discuss.ocaml.org/t/watch-ocaml-behind-the-scenes-exception/12743)

<div class="topic-metadata">

**Author:** [@art-w](https://discuss.ocaml.org/u/art-w)\
**Replies:** 1\
**Last updated:** [September 29, 2023, 5:29pm UTC](https://discuss.ocaml.org/t/watch-ocaml-behind-the-scenes-exception/12743 "2023-09-29T17:29:46Z")

</div>

Hello everyone, Exceptions in OCaml have the reputation of being very fast. As a result, it’s common to use them to signal errors and they are also recommended for advanced control flow. But what’s really happening at r…

---

## [Garbage collection pause statistics?](https://discuss.ocaml.org/t/garbage-collection-pause-statistics/12867)

<div class="topic-metadata">

**Author:** [@AndrasKovacs](https://discuss.ocaml.org/u/AndrasKovacs)\
**Replies:** 6\
**Last updated:** [August 21, 2023, 3:46pm UTC](https://discuss.ocaml.org/t/garbage-collection-pause-statistics/12867 "2023-08-21T15:46:04Z")

</div>

I’d like to get information about GC pauses, for OCaml 5.0.0 (and above). Looking at Module Gc, I only see the verbosity option 0x001 which looks like it might be used to get such information, but when I enabled it it ap…

---

## [CAMLlocal for caml\_callbackN arg array required?](https://discuss.ocaml.org/t/camllocal-for-caml-callbackn-arg-array-required/11012)

<div class="topic-metadata">

**Author:** [@lindig](https://discuss.ocaml.org/u/lindig)\
**Replies:** 6\
**Last updated:** [January 4, 2023, 2:03pm UTC](https://discuss.ocaml.org/t/camllocal-for-caml-callbackn-arg-array-required/11012 "2023-01-04T14:03:10Z")

</div>

I’m using caml\_callbackN and need to create a value array to pass arguments. Looking trough OCaml compiler code I see that this array is not declared as GC roots but I am not sure about this would and would like to ask f…

---

## [Support for clearing GC'ed memory?](https://discuss.ocaml.org/t/support-for-clearing-gced-memory/11071)

<div class="topic-metadata">

**Author:** [@lindig](https://discuss.ocaml.org/u/lindig)\
**Replies:** 18\
**Last updated:** [January 1, 2023, 6:16pm UTC](https://discuss.ocaml.org/t/support-for-clearing-gced-memory/11071 "2023-01-01T18:16:50Z")

</div>

For security reasons it could be desirable that a value that is no longer in use would be overwritten or cleared in some other way. This way such a value would not show up in a process’ core dump, for example. In particu…

---

## [OCaml 64bits on 32bits platforms](https://discuss.ocaml.org/t/ocaml-64bits-on-32bits-platforms/8622)

<div class="topic-metadata">

**Author:** [@EduardoRFS](https://discuss.ocaml.org/u/EduardoRFS)\
**Replies:** 4\
**Last updated:** [October 14, 2021, 2:51pm UTC](https://discuss.ocaml.org/t/ocaml-64bits-on-32bits-platforms/8622 "2021-10-14T14:51:38Z")

</div>

Proposal For a long time OCaml 32bits is not exactly well maintained from a community point of view and that happens mostly because the memory model is different. Couldn’t we have the 64bits memory model running on 32bi…

---

## [Representing data more compactly but unsafely](https://discuss.ocaml.org/t/representing-data-more-compactly-but-unsafely/8489)

<div class="topic-metadata">

**Author:** [@Kakadu](https://discuss.ocaml.org/u/Kakadu)\
**Replies:** 13\
**Last updated:** [September 16, 2021, 3:17pm UTC](https://discuss.ocaml.org/t/representing-data-more-compactly-but-unsafely/8489 "2021-09-16T15:17:12Z")

</div>

I’m collecting cases where people modernized data representation either to store them more compactly or to store some extra data in unused bytes. If it is done using unsafe features of OCaml (or similar language runtime…
