query-json GC Pressure Baseline

May 7, 2026 ยท View on GitHub

This is a local baseline from the stock OCaml runtime. Treat the absolute numbers as machine-specific; the table is mainly useful as a shape check for comparing another runtime, such as OCaml's new_compactor branch, with the same command.

  • Date: 2026-05-07
  • OCaml version: 5.4.0
  • Command: dune exec benchmarks/bench_gc_pressure.exe
  • File: benchmarks/big.json
  • File size: 574908 bytes
  • Iterations per scenario: 8
ScenarioWork sFull major msCompact msAlloc MiBPromoted MiBMajor GCsHeap work MiBHeap major MiBHeap compact MiBFree major MiBFree compact MiBFragments majorFragments compactRSS work MiBRSS compact MiBObserved
parse_drop0.0400.2700.47622.412.0153.41.31.20.70.633432713.09.112944
parse_render_drop0.0640.6350.68938.818.6236.81.31.20.70.633432717.89.14599264
retained_filter_query0.0091.1681.55516.02.434.23.63.50.70.662661912.312.24098
retained_group_by0.0081.2421.6268.02.734.53.63.50.70.662661912.612.21762
retained_render0.0281.4361.46419.32.3911.23.63.50.60.662261920.613.14600882
retained_some_parses0.0433.2023.56422.514.31210.86.05.80.80.693491519.514.112944

Scenarios

  • parse_drop: repeatedly parse JSON and drop each tree.
  • parse_render_drop: parse JSON, pretty-print it, then drop both values.
  • retained_filter_query: keep the parsed JSON live while running filter/map queries.
  • retained_group_by: keep the parsed JSON live while repeatedly grouping results.
  • retained_render: keep the parsed JSON live while repeatedly pretty-printing it.
  • retained_some_parses: parse repeatedly, retaining a few trees to fragment live data.