January 10, 2026
No GC? No chill
Httpz – Zero-Allocation HTTP/1.1 Parser for OxCaml
Blazing-fast web parser with no memory mess; devs brawl over stack vs heap
TLDR: Httpz claims a zero-allocation, ultra-fast web request parser for OxCaml, boasting huge throughput and a built-in file server. Comments erupt over whether avoiding heap memory truly matters, with worries about stack growth and praise for upcoming parallelism — a lively stack vs heap showdown that could reshape server performance.
Httpz promises a speed-demon web parser that keeps everything off the garbage-collected “heap” and on the “stack” — translation: it’s designed to be fast and predictable. The dev says it hits 14.6 million requests per second and ships a static file server that can juggle 10,000 connections. There’s even a tease for Linux’s ultra-fast I/O trick, io_uring, coming soon. Author avsm struts into the thread with receipts, flashing a quirky OxCaml type signature and bragging about “data-race free parallelism.” Fans like infamouscow cheer, expecting big things from OxCaml.
Then the drama: skeptics ask the forbidden question — why zero allocations? Commenter nospice pokes at the point: maybe cache behavior matters more than where memory lives. Messe worries about “local lists” on the stack turning into a bottomless pit: “Does this mean unbounded stack growth?” Cue the meme brigade: gethly dunks with “ocaml looks more like a spec than actual code,” spawning a quick “do you even GC?” riff. The thread turns into a spicy stack-vs-heap showdown, half performance flex, half philosophy fight. Some call it speed theater; others love the zero-copy, bare-metal vibes. Meanwhile, avsm keeps shipping, promising parallelism while the crowd argues if “no allocations” is genius or just bragging rights.
Key Points
- •Httpz is an HTTP/1.1 parser/serializer for OxCaml aiming for zero heap allocations via unboxed records and local lists.
- •Architecture uses span-based parsing, direct bigstring I/O, and a reusable 32KB read buffer to minimize allocations.
- •Benchmarks show 2.13x–3.14x speedups over an Eio-based parser (httpe) and up to 829x fewer allocation words.
- •Throughput reaches 14.6M requests/sec versus 4.6M for httpe; detailed timings list operations with ~3 heap words.
- •An Async-based static file server is included with zero-copy I/O, MIME detection, security features, and 10,000-connection handling; io_uring support on Linux is planned.