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?

Show HN: Hound Media Server – Media Server Alternative to Plex+Stremio

https://github.com/Hound-Media-Server/hound
1•nearbyyak•27s ago•0 comments

Why India Baffles China

https://economist.com/asia/2026/09/06/why-india-baffles-china
1•andsoitis•36s ago•0 comments

Show HN: Wg-admin – web UI for an existing WireGuard host

https://github.com/logimaxx/wg-admin
1•vsergione•1m ago•0 comments

Beautiful Messaging at Scale

https://www.vestaboard.com/note-array
1•andsoitis•2m ago•0 comments

Try real Omarchy Linux in your browser

https://tryomarchy.dev/
2•emirb•3m ago•0 comments

Tell HN: OpenAI brings back 5 hour limit for plus and business standard users

1•spwa4•4m ago•0 comments

Why front ends fail when you approach them like a back end

https://marijkeluttekes.dev/blog/articles/2026/03/16/why-frontends-fail-when-you-approach-them-li...
1•birdculture•5m ago•0 comments

Show HN: A DIY pure sine-wave solar inverter I built from scratch

https://www.mch170.com/projects/mcinv
2•MCH170•5m ago•0 comments

Rttx – a tiling terminal for GNOME first stable release

https://github.com/IllyaYalovyy/rttx
1•zero-ground-445•5m ago•0 comments

MCP server architecture for platform teams

https://pipelineandprompts.com/posts/mcp-server-architecture-platform-engineering-kubernetes/
1•daytonflyers•5m ago•0 comments

Show HN: Real-time manga and manhwa translation from your phone

https://pawakalabs.com/products/madomi/
1•adibzaini•8m ago•1 comments

My full statement regarding DOOM Eternal (2022)

https://medium.com/@mickgordon/my-full-statement-regarding-doom-eternal-5f98266b27ce
1•CharlesW•9m ago•0 comments

NetBSD 11 from Scratch

https://meanmicio.org/2026/09/06/netbsd-11-from-scratch/
1•birdculture•10m ago•0 comments

Apple's "Think Different" inspired ad made by AI

https://twitter.com/Noahsarc1000/status/2096989380774903883
1•nhannguyenkooln•12m ago•1 comments

Ask HN: What LLM are you using?

1•daytonflyers•12m ago•0 comments

Using large language models for research in the natural sciences

https://github.com/Open-Science-Ledger/how-to-train-your-slop-cannon
1•mathgenius•21m ago•0 comments

Show HN: SharpLineup: fantasy football projections priced from betting markets

https://sharplineup.com
1•autoap•23m ago•0 comments

Israeli ministers keep telling everyone their brutal plans, why are they ignored

https://www.theguardian.com/commentisfree/2026/sep/07/israeli-ministers-brutal-plans-palestinians...
6•hebelehubele•24m ago•1 comments

Making software hurts now

https://notes.erlend.sh/3muwdtclths2d
3•erlend_sh•25m ago•0 comments

Where every AI coding tool keeps its config

https://github.com/moneytool/agentmeld/blob/main/docs/where-ai-coding-tools-keep-their-config.md
2•moneytool•25m ago•0 comments

Stockfish 19

https://stockfishchess.org/blog/2026/stockfish-19/
3•atiedebee•27m ago•0 comments

Benchmarks show scores. Dashboards show usage. What ships?

https://pragmatikos.ai/
1•judsd•28m ago•0 comments

Show HN: LLM Council: survival-of-the-fittest multi-modal deliberation

https://github.com/Moiz-I/council-of-claude
1•moiz-i•28m ago•0 comments

Show HN: Evidence-linked forensic financial investigation

https://exitprotocols.com/
1•cd_mkdir•31m ago•1 comments

Phairplay – AirPlay and Miracast for Android TV

https://github.com/mazer666/PhairPlay
1•theturtletalks•32m ago•0 comments

Do We Still Need Burp Suite for Web Security Testing?

https://medium.com/@Koukyosyumei/do-we-still-need-burp-suite-for-web-security-testing-00f068851d30
3•syumei•34m ago•1 comments

The New US Dollar, the One Epstein Built

https://theleahfiles.substack.com/p/the-new-us-dollar-the-one-epstein
5•xrd•34m ago•0 comments

I'm going Founder Mode on my cancer

https://sijbrandij.substack.com/p/im-going-founder-mode-on-my-cancer
2•tosh•36m ago•0 comments

Mod runs DLSS 5 neural rendering on a second GPU via ReShade, boosts FPS 127%

https://www.tomshardware.com/pc-components/gpus/astonishing-mod-runs-nvidia-dlss-5-on-a-second-gp...
1•sbulaev•37m ago•0 comments

Company does not have processes. It has habits

https://ai.levelbrook.com/playbook/you-do-not-have-processes/
1•entaroadun123•38m ago•0 comments