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?

Valve's version of Android on Linux (based on Waydroid) is now called Lepton

https://www.gamingonlinux.com/2025/12/valves-version-of-android-on-linux-based-on-waydroid-is-now...
1•wicket•1m ago•0 comments

What I learned building an opinionated and minimal coding agent

https://mariozechner.at/posts/2025-11-30-pi-coding-agent/
1•gmays•2m ago•0 comments

Show HN: TrackerNews – Keyword monitoring and insight extraction

https://trackernews.app/
1•winchester6788•3m ago•0 comments

My redirect rules from 2013 still work and yours don't

https://idiallo.com/blog/my-redirect-rules-from-2013-still-work
3•foxfired•4m ago•0 comments

JEP 504: Remove the Applet API

https://openjdk.org/jeps/504
1•matthews3•4m ago•1 comments

Pentagon Launches $1B Program to Buy Hundreds Of Thousands Of Kamikaze Drones

https://www.twz.com/air/pentagon-launches-1b-program-to-rapidly-buy-hundreds-of-thousands-of-kami...
2•breve•7m ago•0 comments

The case of the 500-mile email (2002)

https://www.ibiblio.org/harris/500milemail.html
5•Timothee•7m ago•0 comments

Solve Go Challenge: Octantconway

https://github.com/plutov/practice-go/tree/master/octantconway
2•todsacerdoti•8m ago•0 comments

Why Won't the Media Report Accurately on Road Deaths?

https://jakecoppinger.com/2025/12/why-wont-the-media-report-accurately-on-road-deaths/
2•jakecopp•9m ago•1 comments

Show HN: ThesisBoard – Trello for Investment Research

https://thesisboard.com/
1•egobrain27•11m ago•0 comments

Building a fintech platform's mobile app

https://hackclub.com/fiscal-sponsorship/mobile/
1•JustSkyfall•11m ago•0 comments

`npx vercel` opens a project

https://ando.so/company
1•frootoftheloom•12m ago•0 comments

Catalogue of Moulded and Ornamental Brick (1892)

https://archive.org/details/central-press-brick-1900s-a
1•georgefrowny•12m ago•0 comments

Social identification with a team boosts fans' social well-being

https://phys.org/news/2025-11-social-identification-team-boosts-fans.html
2•PaulHoule•13m ago•0 comments

StackOverflow: AI Assist

https://stackoverflow.com/ai-assist
2•Bootvis•15m ago•0 comments

Windows 11 growth slows as millions stick with Windows 10

https://www.theregister.com/2025/12/03/windows_11_statcounter/
1•naves•15m ago•0 comments

Michael Levin on Pain as Agent, Healing as Alignment

https://essays.debugyourpain.com/p/michael-levin-on-pain-as-agent-healing
1•yichab0d•15m ago•1 comments

Mixtures of dietary nutrients lessen behavioral deficits in mouse autism models

https://journals.plos.org/plosbiology/article?id=10.1371/journal.pbio.3003231
2•bookofjoe•16m ago•0 comments

Show HN: I built a trending books by month Bump Chart with Hardcover data

https://hardcover.app/labs/popular-by-month
1•dyogenez•17m ago•0 comments

Source code to Sega Saturn game "Powerslave" released

https://github.com/Lobotomy-Software/SlaveDriver-Engine
1•alexjplant•19m ago•0 comments

Comments on smartphone ban from high school teacher

https://marginalrevolution.com/marginalrevolution/2025/09/from-the-comments-39.html
2•surprisetalk•21m ago•0 comments

Hiring: Damned If You Do, Damned If You Don't

https://www.factorysettings.org/p/hiring-damned-if-you-do-damned-if
1•surprisetalk•22m ago•0 comments

Some Economics of Artificial Super Intelligence

https://papers.ssrn.com/sol3/papers.cfm?abstract_id=5728702
1•surprisetalk•22m ago•0 comments

Rock Paper Scissors Is a Game of Skill

https://collisteru.substack.com/p/rock-paper-scissors-is-a-game-of
1•surprisetalk•22m ago•0 comments

Alzheimer's is the symptom, not the problem

https://1393.xyz/blog/alzheimers-is-the-symptom-not-the-problem
2•rdgthree•22m ago•0 comments

Vibe Code Like It's 1986

https://github.com/AvitalTamir/vibecommander
1•fatliverfreddy•23m ago•1 comments

The Real-Life Hunt for Red October Happened 50 Years Ago

https://www.twz.com/sea/the-real-life-hunt-for-red-october-happened-50-years-ago
1•breve•23m ago•0 comments

Show HN: MetaConvert – Free PDF and Image Conversion Tools

https://metaconvert.blogspot.com/
2•MetaConvert•23m ago•0 comments

After nearly 30 years, Crucial will stop selling RAM to consumers

https://arstechnica.com/gadgets/2025/12/after-nearly-30-years-crucial-will-stop-selling-ram-to-co...
10•downrightmike•25m ago•3 comments

Affiliate Program

https://growup-labs.com/
1•kelvb•25m ago•1 comments