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•9mo ago

Comments

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

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

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

Ask HN: Gmail/Draft Problems?

1•sanj•1m ago•0 comments

TPU I built from scratch – RTL, MLIR compiler, PJRT runtime, runs Jax

https://twitter.com/PatrickToulme/status/2017706776288719194
1•patrick_toulme•3m ago•0 comments

Surfing Through the Digital Airwaves: A History of Internet Radio (2020)

https://thehistoryoftheweb.com/internet-radio/
1•notagoodidea•4m ago•0 comments

Conrad Gessner

https://en.wikipedia.org/wiki/Conrad_Gessner
1•petethomas•4m ago•0 comments

Michael Ovitz: The Business of Relationships

https://fs.blog/knowledge-project-podcast/michael-ovitz/
1•feross•5m ago•0 comments

Housing program helped kids escape poverty – by changing who they befriended

https://www.npr.org/2026/01/28/nx-s1-5691692/hope-vi-public-housing-opportunity-insights-raj-chetty
2•marojejian•6m ago•0 comments

AI-augmented photon-trapping spectrometer-on-a-chip on silicon platform

https://www.spiedigitallibrary.org/journals/advanced-photonics/volume-8/issue-01/016008/AI-augmen...
1•PaulHoule•7m ago•0 comments

Michael Beck, 65, Dies; First to Report Symptoms of 'Havana Syndrome'

https://www.nytimes.com/2026/01/29/us/michael-beck-dead.html
2•bookofjoe•8m ago•2 comments

Kaidan IM 0.15.0: Audio/Video Calls and Integrated Search Field – XMPP

https://www.kaidan.im/2026/01/30/kaidan-0.15.0/
1•neustradamus•11m ago•0 comments

33rpm – a spinning vinyl screensaver for your Mac

https://33rpm.noonpacific.com/
1•kaniksu•12m ago•0 comments

Crazy shit linkers do: Relaxation

https://fzakaria.com/2026/01/30/crazy-shit-linkers-do-relaxation
2•ingve•13m ago•0 comments

Is there a platform for devs to share repositories in hopes of OSS contributors?

2•anshyyy•15m ago•1 comments

Show HN: Hackmenot – Security scanner for AI-generated code

https://github.com/b0rd3aux/hackmenot
1•b0rd3aux•15m ago•0 comments

Signal president warns AI agents are making encryption irrelevant

https://cyberinsider.com/signal-president-warns-ai-agents-are-making-encryption-irrelevant/
1•u1hcw9nx•19m ago•0 comments

Best of Moltbook

https://www.astralcodexten.com/p/best-of-moltbook
1•feross•21m ago•0 comments

Looking for Founders that have SHIPPED and are looking to PARTNER UP

https://www.cofounder-hunt.com
1•PEGEBE•21m ago•1 comments

For most flagged articles, nearly every cited sentence failed verification

https://wikiedu.org/blog/2026/01/29/generative-ai-and-wikipedia-editing-what-we-learned-in-2025/
3•ColinWright•23m ago•1 comments

I still don't understand this SYN attack, but now I can block it easily

https://boston.conman.org/2026/01/28.2
1•birdculture•27m ago•0 comments

Outsourcing Thinking

https://erikjohannes.no/posts/20260130-outsourcing-thinking/index.html
2•todsacerdoti•30m ago•0 comments

Convicted ex-Google engineer faces up to 175 year sentence for AI tech theft

https://www.reuters.com/legal/government/ex-google-engineer-convicted-stealing-ai-secrets-chinese...
2•delichon•31m ago•0 comments

Two lines of code for making your MCPs compatible with OpenAI libs

https://github.com/stepacool/mcphero
1•Arterialist•34m ago•0 comments

Custom machine kept man alive without lungs for 48 hours

https://arstechnica.com/health/2026/01/custom-machine-kept-man-alive-without-lungs-for-48-hours/
3•ben_w•35m ago•0 comments

Private Credit Worries Bedevil Shares of Biggest Buyout Shops

https://www.bloomberg.com/news/articles/2026-01-31/private-credit-worries-bedevil-shares-of-bigge...
1•zerosizedweasle•35m ago•0 comments

Humans Tap into a 'Collective Unconscious'–and It May Be Shaping Brains

https://www.popularmechanics.com/science/a70012418/shared-consciousness/
3•general_reveal•35m ago•1 comments

GlassWorm Loader Hits Open VSX via Developer Account Compromise

https://socket.dev/blog/glassworm-loader-hits-open-vsx-via-suspected-developer-account-compromise
1•feross•35m ago•0 comments

What we can learn from tiny traces of ancient blood chemicals

https://theconversation.com/life-in-fossil-bones-what-we-can-learn-from-tiny-traces-of-ancient-bl...
2•janandonly•36m ago•0 comments

James Mickens' Tenure Announcement

https://mickens.seas.harvard.edu/tenure-announcement-april-2019/
2•nemosaltat•37m ago•1 comments

The State of WebAssembly – 2025 and 2026

https://platform.uno/blog/the-state-of-webassembly-2025-2026/
2•breve•37m ago•0 comments

"You can post anything to Moltbook"

https://twitter.com/galnagli/status/2017573842051334286
2•habinero•38m ago•0 comments

Show HN: Save upto 70% of API usage in agentic development

https://github.com/AffanShaikhsurab/COON
1•affanshaiksurab•39m ago•0 comments