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?

Woolyss Chromium website shutting down 2026-08-31

https://chromium.woolyss.com/
1•brycewray•55s ago•0 comments

Building a Korean ambiguity solver fast enough to skip the GPU: 7,300 words/SEC

https://kimchi-reader.app/blog/int8-cpu-korean-disambiguation
1•alaanor•1m ago•0 comments

AI and the invisible newcomer in open source

https://blog.stdlib.io/ai-and-the-invisible-newcomer-in-open-source/
1•kgryte•2m ago•0 comments

World Capitals Voronoi

https://www.jasondavies.com/maps/voronoi/capitals/
1•vincnetas•3m ago•1 comments

Amid a flood of AI advances astrophysicists are questioning soul of their field

https://www.science.org/content/article/amid-flood-ai-advances-astrophysicists-are-questioning-so...
1•bookofjoe•3m ago•0 comments

Ideogram 4.0

https://ideogram.ai/models/4.0/
1•pentagrama•3m ago•0 comments

Amazon Cognito now supports multi-Region replication

https://aws.amazon.com/about-aws/whats-new/2026/06/amazon-cognito-multi-region/
3•mooreds•3m ago•0 comments

Life – an artificial life simulation with Φ* integrated information

https://github.com/cosmosoneness/Cosmos-Research-Institute/tree/main/Emulation/Life
1•cosmosoneness•3m ago•0 comments

Show HN: OceanEye – an open-source interactive 3D atlas of ocean life

https://oceaneye.woodydesign.io/en/
1•woodydesign•4m ago•0 comments

Show HN: Xa11y – cross-platform desktop automation via accessibility trees

https://xa11y.dev/
1•_crowecawcaw•4m ago•0 comments

France took the nuclear option to make Putin think twice

https://www.telegraph.co.uk/world-news/2026/05/26/how-europe-learnt-to-love-the-bomb/
1•speckx•5m ago•0 comments

Meta AI Instagram Hack Wasn't About Authentication. It Was About Authorization

https://www.cybersecurity-insiders.com/the-meta-ai-instagram-hack-wasnt-about-authentication-it-w...
1•mooreds•6m ago•0 comments

Applied Reverse Engineering Course

https://revers.engineering/applied-reverse-engineering-series/
1•Iuz•6m ago•0 comments

'The rich are living a golden age under Trump'

https://english.elpais.com/economy-and-business/2026-06-06/the-popularizer-of-the-k-shaped-econom...
1•mooreds•6m ago•0 comments

Introduction to nixidy – Kubernetes GitOps with Nix

https://codedbearder.com/posts/nixidy-part-1-introduction/
1•granra•6m ago•0 comments

Property-Based Testing

https://tybug.dev/property-testing/
1•tybug•7m ago•0 comments

A Farmer Donated Land to Turn into a Park. The City Is Building a Data Center

https://www.404media.co/a-farmer-donated-land-to-turn-into-a-park-the-city-is-building-a-massive-...
1•greedo•8m ago•0 comments

Reading of OpenAI's Self-Improving Tax Agents

https://olshansky.info/posts/2026-06-08-reading-of-openais-self-improving-tax-agents
2•Olshansky•9m ago•0 comments

xAI is looking more like a datacentre REIT than a frontier lab

https://martinalderson.com/posts/xais-new-rental-business/
1•martinald•9m ago•0 comments

Show HN: Levi – run AlphaEvolve on your Claude Code/Codex for dirt cheap

https://ttanv.github.io/levi/
2•ttanv•10m ago•0 comments

"a game of court intrigue where AI simulates the various courtiers"

https://substack.com/@alicemaz/note/c-265000587
1•pavel_lishin•11m ago•0 comments

The Myth, the Mythos and the Man

https://om.co/2026/06/07/the-myth-the-mythos-and-the-man/
1•herbertl•12m ago•0 comments

Unhook, extension to block YouTube suggestion feeds, comments, and more

https://unhook.app/
1•sanbor•13m ago•0 comments

Diet Culture Ruins Lives

https://lithub.com/how-diet-culture-ruins-lives/
1•PaulHoule•13m ago•0 comments

"Chat is dead": OpenAI preps overhaul of ChatGPT

https://arstechnica.com/ai/2026/06/chat-is-dead-openai-preps-overhaul-of-chatgpt/
1•kylemaxwell•13m ago•0 comments

Somalia: The way forward – fourteen years later

https://wardheernews.com/somalia-the-way-forward-fourteen-years-later/
1•paulpauper•13m ago•0 comments

Biological Origin for the Ancient Alkanes Preserved in a Martian Mudstone

https://journals.sagepub.com/doi/10.1177/15311074261417879
2•simonebrunozzi•13m ago•0 comments

Alan Riding, Times Correspondent in Latin America and Paris, Dies at 82

https://www.nytimes.com/2026/06/06/business/media/alan-riding-dead.html
1•paulpauper•14m ago•0 comments

Hayekian Literary Criticism

https://marginalrevolution.com/marginalrevolution/2026/06/hayekian-literary-criticism.html
1•paulpauper•15m ago•0 comments

Spread

https://github.com/odipar/spread
1•tosh•16m ago•0 comments