frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Packed Data Support in Haskell

https://arthi-chaud.github.io/posts/packed/
77•matt_d•11mo ago

Comments

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

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

carterschonwald•11mo ago
One thing that sometimes gets tricky in these things is handling Sub term sharing. I wonder how they implemented it.
tlb•11mo 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•11mo 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•11mo 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•11mo ago
honestly i wish more stuff worked this way - fewer hops in memory always makes me happy
lordleft•11mo ago
This was very well written. Excellent article!
NetOpWibby•11mo ago
Is this like MessagePack for Haskell?

Adversarial distillation

https://www.frontiermodelforum.org/issue-briefs/issue-brief-adversarial-distillation/
1•hhs•7m ago•0 comments

DOOM runs in ChatGPT and Claude

https://chrisnager.com/blog/doom-runs-in-chatgpt-and-claude/
1•chrisnager•8m ago•0 comments

Landmark ancient-genome study shows surprise acceleration of human evolution

https://www.nature.com/articles/d41586-026-01204-5
4•unsuspecting•11m ago•0 comments

Custom .af video format for WebCodecs: frame-accurate playback without <video>

https://github.com/activetheory/activeframe
1•luruke•14m ago•0 comments

DESI Completes Planned 3D Map of the Universe and Continues Exploring

https://newscenter.lbl.gov/2026/04/15/desi-completes-planned-3d-map-of-the-universe-and-continues...
1•bookofjoe•15m ago•0 comments

"Am I Crazy?" [Wading Through AI – Episode 3] [video]

https://www.youtube.com/watch?v=Sp1EmFRDquA
1•rglover•20m ago•0 comments

Littlebird raises $11M for its AI-assisted 'recall' tool

https://techcrunch.com/2026/03/23/littlebird-raises-11m-to-capture-context-from-your-computer-so-...
1•PaulHoule•23m ago•0 comments

Update: EntropyLoop is now the first AI native MCP'd Quantum RNG

https://github.com/QuantumVillage/EntropyLoop
1•unprovable•24m ago•0 comments

DriveLogs (DMV-ready driving hour logs for teen drivers, iOS)

https://www.drivelogs.app/
1•rodrifranco•25m ago•0 comments

Japan reveals new name for 40C-and-hotter days after blistering summer

https://www.bbc.com/news/articles/crr185nx0n9o
1•throw0101d•26m ago•0 comments

Show HN: External admission gate for GitHub Actions before execution

https://ai-admissibility.com/
1•pinfloyd•27m ago•0 comments

3 Hours with Claude 4.7: functional study webapp and remote MCP – Oneshotted

https://github.com/AmmarSaleh50/study-dashboard-demo
1•AmmarSaleh50•27m ago•1 comments

Kefir C17/C23 Compiler

https://sr.ht/~jprotopopov/kefir/
1•conductor•28m ago•0 comments

Tell HN: Security Incident at Porter (YC S20)

3•leetrout•32m ago•0 comments

The AI Rewrite Dilemma

https://lh3.github.io/2026/04/17/the-ai-rewrite-dilemma
1•jryb•32m ago•0 comments

Shakespeare owned a house in London. We know where it was

https://www.ctvnews.ca/world/article/new-discovery-solves-mystery-of-the-location-of-shakespeares...
1•gnabgib•35m ago•0 comments

Ask HN: Founders, what are you building that survives a Mythos-class model?

1•deep-thinker•39m ago•0 comments

Folding Ideas: Why was I invited to Beast Studios? [video]

https://www.youtube.com/watch?v=0dwagg5wYY4
1•minimaxir•42m ago•1 comments

ListifyText – Turn messy text into clean, structured lists instantly

https://listifytext.com/
1•dguioiutrdrtui•45m ago•0 comments

Terminator: Code You See Onscreen [video]

https://www.youtube.com/watch?v=NebvccLHutQ
1•ohjeez•46m ago•0 comments

Show HN: Pyra – a Python toolchain experiment inspired by uv and Bun

https://github.com/treyorr/pyra
3•trey-orr•51m ago•0 comments

Stop Burning Money on UGC Creators: Generate Viral Ads with AI in Seconds

https://ecomscalingpro.substack.com/p/how-i-went-from-0-to-scaling-my-shopify
3•Locas•54m ago•0 comments

Only 13% of emails are written by people

https://english.elpais.com/technology/2026-04-15/only-13-of-emails-are-written-by-people-and-more...
3•geox•55m ago•1 comments

Kevin Weil and Bill Peebles exit OpenAI as company continues to shed side quests

https://techcrunch.com/2026/04/17/kevin-weil-and-bill-peebles-exit-openai-as-company-continues-to...
5•spenvo•56m ago•1 comments

Cal.com OSS project goes closed source due to AI

https://cal.com/de/blog/cal-com-goes-closed-source-why
2•samspenc•58m ago•2 comments

Ryan Mather: My tips for getting the best results out of Claude Design

https://twitter.com/flomerboy/status/2045162321589252458
6•taubek•1h ago•1 comments

Show HN: Mind-OS – First free online AI dependency self‑assessment

https://iamalex-afk.github.io/human-os-patch-33-protocols/
2•bitkin_dev•1h ago•0 comments

The big business of survival bunkers

https://www.economist.com/united-states/2026/04/16/the-big-business-of-survival-bunkers
3•andsoitis•1h ago•0 comments

High Amplitude Disagreeableness

https://staysaasy.com/startups/2026/04/15/high-amplitude-disagreeableness.html
2•weltview•1h ago•0 comments

A simplified model of Fil-C

https://www.corsix.org/content/simplified-model-of-fil-c
40•aw1621107•1h ago•5 comments