frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Packed Data Support in Haskell

https://arthi-chaud.github.io/posts/packed/
77•matt_d•1y ago

Comments

nine_k•1y ago
> Introducing the ‘packed’ data format, a binary format that allows using data as it is, without the need for a deserialisation step. A notable perk of this format is that traversals on packed trees is proven to be faster than on ‘unpacked’ trees: as the fields of data structures are inlines, there are no pointer jumps, thus making the most of the L1 cache.

That is, a "memory dump -> zero-copy memory read" of a subgraph of Haskell objects, allowing to pass such trees / subgraphs directly over a network. Slightly reminiscent of Cap'n Proto.

90s_dev•1y ago
We are always reinventing wheels. If we didn't, they'd all still be made of wood.
Zolomon•1y ago
They mention this in the article.
spockz•1y ago
It reminds me more of flat buffers though. Does protobuf also have zero allocation (beyond initial ingestion) and no pointer jumps?
cstrahan•1y ago
No, one example of why being variable sized integers.

See https://protobuf.dev/programming-guides/encoding/

carterschonwald•1y ago
One thing that sometimes gets tricky in these things is handling Sub term sharing. I wonder how they implemented it.
tlb•1y ago
> the serialised version of the data is usually bigger than its in-memory representation

I don’t think this is common. Perhaps for arrays of floats serialized as JSON or something. But I can’t think of a case where binary serialization is bigger. Data types like maps are necessarily larger in memory to support fast lookup and mutability.

nine_k•1y ago
I suppose all self-describing formats, like protobuf, or thrift or, well, JSON are bigger than the efficient machine representation, because they carry the schema in every message, one way or another.
IsTom•1y ago
If you use a lot of sharing in immutable data it can grow a lot when serializing. A simple pathological example would be a tree that has all left subtrees same as the right ones. It takes O(height) space in memory, but O(2^height) when serialized.
gitroom•1y ago
honestly i wish more stuff worked this way - fewer hops in memory always makes me happy
lordleft•1y ago
This was very well written. Excellent article!
NetOpWibby•1y ago
Is this like MessagePack for Haskell?

A Quantum simulator for major chip types, for AI agents, now 6x faster

https://github.com/vicena-labs/quantum-circuit-simulator
1•AI4Science•5s ago•1 comments

Show HN: Drop-in replacement for the remove.bg API, which shuts down Dec 1

https://airgallery.com/api
1•willpschulz•1m ago•0 comments

Why is LLM inference challenging?

https://mehrdadmahabadi.com/blog/why-is-llm-inference-hard.html
1•mehrdad3301•1m ago•0 comments

64GB VRAM MTT GPUs Coming?

1•emilss•2m ago•1 comments

CLI for AI agents to access health data natively

1•pidaparti•3m ago•0 comments

Percona Database Service Is Now Open Source

https://www.percona.com/blog/percona-database-service-open-source/
1•andrewstetsenko•4m ago•0 comments

radius-proof: proof that nested rounded rectangles need R = R and d

https://github.com/steveruizok/radius-proof
1•bpierre•4m ago•0 comments

Show HN: HealthBar – Open-source macOS menu bar app that tracks status pages

https://github.com/vladforfutdinov/health-bar
1•vladfrandom•6m ago•0 comments

OpenAI is finally merging ChatGPT's Chat and Work tabs

https://techcrunch.com/2026/11/02/openai-is-finally-merging-chatgpts-chat-and-work-tabs/
2•hn-aarvin•10m ago•0 comments

The FCC has authorized SpaceX to deploy 1M satellites

https://arstechnica.com/space/2026/11/the-fcc-has-authorized-spacex-to-deploy-1-million-satellites/
3•LorenDB•11m ago•1 comments

The Last Boring Slide

https://claude.ai/artifact/Cy2d8Vn63CnzCtonA1LSah#questions-3
2•himata4113•12m ago•0 comments

Deliberately run your time, energy and resources below 80% capacity

https://twitter.com/Voxyz_ai/status/2125591320341229890/photo/1
2•jger15•12m ago•1 comments

The Curse of Impunity

https://backofmind.substack.com/p/the-curse-of-impunity
1•hn-aarvin•13m ago•0 comments

Skala

https://bjango.com/mac/skala/
1•robenkleene•15m ago•0 comments

Diablo 2

https://www.filfre.net/2026/11/diablo-ii/
1•olup•16m ago•0 comments

Against All Odds: The Mathematics of 'Provably Fair' Casino Games

https://philippdubach.com/posts/against-all-odds-the-mathematics-of-provably-fair-casino-games/
2•windsurfer•18m ago•1 comments

Approaching Technology Like the Amish

https://smartpeopleiknow.com/2026/11/25/on-approaching-technology-like-the-amish/
1•speckx•18m ago•1 comments

Diffusion Gemma

https://deepmind.google/models/gemma/diffusiongemma/
4•SweetSoftPillow•20m ago•0 comments

Guitar Hero, but for Hand Bells

https://dingdonghero.com
3•devbytes•20m ago•1 comments

Three Expropriations of Modernity: Land, Attention, Skill

https://medium.com/@smoking2man/three-expropriations-of-modernity-land-attention-skill-20750f9bb410
4•Aldus551•21m ago•0 comments

A Linux environment and Ghostty-based terminal for iOS

https://github.com/swipt-automation/Swipterm
3•polyrand•23m ago•0 comments

Nexus, an open source app for local development replacing paid SaaS like Herd

https://github.com/NexusLocal/nexus
3•tklaversma•24m ago•0 comments

What does a software factory cost?

https://zarar.dev/software-factory/
3•recroad•24m ago•0 comments

Lessons from running DeepSeek's DSec sandbox design on public cloud

https://vibrantlabs.com/research/swarmbox
2•jjmachan•24m ago•0 comments

State Machines > Skills

https://adamgrant.micro.blog/2026/11/25/state-machines-are-better-than.html
3•hidelooktropic•24m ago•0 comments

CSS-in-JS Benchmarks

https://github.com/jantimon/css-in-js-bench
1•gajus•25m ago•0 comments

Plato's Key

https://hazyresearch.stanford.edu/blog/2026-11-25-platos-key
1•jumploops•27m ago•0 comments

Spending 35B Opus 5.5 Tokens to Write a Symphony

https://danprice.ai/blog/opus-symphony
3•halfprice06•28m ago•0 comments

Stop trying to make lock-in happen: Why you should build on ATProto

https://tropopause.pckt.blog/stop-trying-to-make-lock-in-happen-9ndxs7z
1•overcommitted•29m ago•0 comments

The Birds Are Listening: Scientists Used Seabirds to Track Hidden Ships

https://www.404media.co/the-birds-are-listening-scientists-used-seabirds-to-track-hidden-ships/
2•MBCook•29m ago•0 comments