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

Comments

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

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

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

Nebula Awards Yelled at Until They Ban Use of AI by Nominees

https://gizmodo.com/nebula-awards-yelled-at-until-they-completely-ban-use-of-ai-by-nominees-20007...
3•gnabgib•3m ago•0 comments

Why Chinese Energy Projects Are Facing a Backlash in the Balkans

https://oilprice.com/Energy/Energy-General/Why-Chinese-Energy-Projects-Are-Facing-a-Backlash-in-t...
1•PaulHoule•3m ago•0 comments

An amateur codebreaker may have just solved the Black Dahlia and Zodiac killings

https://www.latimes.com/california/story/2025-12-23/black-dahlia-zodiac-killings-connected-one-ki...
1•davweb•3m ago•0 comments

Kimwolf Exposed: The Android Botnet with 1.8M Infected Devices

https://blog.xlab.qianxin.com/kimwolf-botnet-en/
1•_____k•4m ago•0 comments

Oral History of Jeffrey Ullman [video]

https://www.youtube.com/watch?v=wROQBhBuq1w
1•matt_d•4m ago•0 comments

Energy Predictions 2025

https://caseyhandmer.wordpress.com/2025/12/08/energy-predictions-2025/
1•simonebrunozzi•5m ago•0 comments

We Become What We Behold

https://ncase.itch.io/wbwwb
1•gmays•6m ago•0 comments

Farewell, Bandhub. I will miss you (2019)

https://garybadger.com/2019/03/03/farewell-bandhub-i-will-miss-you/
1•Aldipower•9m ago•0 comments

Old-school rotary phone dials into online meetings

https://www.theregister.com/2025/11/24/rotary_phone_online_meetings/
2•ohjeez•9m ago•0 comments

Microsoft bets on AI to modernize Windows

https://www.windowscentral.com/microsoft/windows-11/my-goal-is-to-eliminate-every-line-of-c-and-c...
1•sanqui•10m ago•2 comments

Puzzle Designers Search for That 'Satisfying Click'

https://www.nytimes.com/2025/12/22/science/games-puzzle-design.html
1•robinhouston•12m ago•0 comments

Context is all you need

https://fakepixels.substack.com/p/context-is-all-you-need
2•walterbell•14m ago•0 comments

Top MCP tools for software architects

https://icepanel.io/blog/2025-11-05-top-mcp-tools-for-software-architects
1•shehabas•14m ago•0 comments

Nature Programming Language

https://nature-lang.org/
1•birdculture•16m ago•0 comments

Exposing Honey's Evil Business Model Part 2 [video]

https://www.youtube.com/watch?v=wwB3FmbcC88
3•busymom0•18m ago•1 comments

LLVM AI Policy and Automatic Bazel Fixes

https://www.phoronix.com/news/LLVM-AI-Tool-Policy-RFC
1•boomanaiden154•20m ago•0 comments

Smokejumping

https://heidiwaterhouse.com/smokejumping/
1•mooreds•21m ago•0 comments

The Null Pointer Identity: Debugging the Architecture of the Chinese Self

https://suggger.substack.com/p/the-null-pointer-identity-debugging
1•Suggger•24m ago•1 comments

Progress on the Digital Euro

https://www.ecb.europa.eu/euro/digital_euro/html/index.en.html
2•janandonly•26m ago•1 comments

On the rural Colorado plains, cancer patients rely on this traveling oncologist

https://coloradosun.com/2025/12/21/rural-colorado-plains-cancer-patients-traveling-oncologist/
2•mooreds•27m ago•0 comments

Fuck You, I Won't Use Tailwind

https://fuckyouiwontusetailwind.com
29•csspurist•27m ago•18 comments

Illicit economies, organized crime worsen Amazon deforestation in 2025

https://www.upi.com/Top_News/World-News/2025/12/23/latam-amazon-crime-illegal-logging-mining/1761...
1•Bondi_Blue•28m ago•0 comments

Writing Good Definitions Comes Down to One Basic Rule

https://cacm.acm.org/blogcacm/writing-good-definitions-comes-down-to-one-basic-rule/
1•vinipolicena•28m ago•0 comments

Searching for Soul in Roblox

https://meghanboilard.substack.com/p/searching-for-soul-in-roblox
1•bookofjoe•29m ago•0 comments

Jason Furman on the new economic data

https://www.nytimes.com/2025/12/23/opinion/gdp-numbers-economy-job-numbers.html
1•paulpauper•30m ago•0 comments

The Debunking of Oliver Sacks

https://www.thefp.com/p/the-debunking-of-oliver-sacks
2•paulpauper•30m ago•0 comments

My Art of Accomplishment Retreat

https://eriktorenberg.substack.com/p/my-art-of-accomplishment-retreat
1•paulpauper•31m ago•0 comments

Bari Weiss's Audience of One

https://www.theatlantic.com/politics/2025/12/cbs-news-bari-weiss-trump-media-influence/685381/
4•breve•36m ago•2 comments

Show HN: VibecodePrompts – Reduce prompt friction for vibe-coding

https://vibecodeprompts.cloud
1•rubenhellman•38m ago•0 comments

Show HN: TypeScript template for building ChatGPT Apps

https://github.com/pomerium/chatgpt-app-typescript-template
3•nickytonline•39m ago•0 comments