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•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?

Trump phone data leak [video]

https://www.youtube.com/watch?v=c8TwGH1B5wA
1•colonCapitalDee•28s ago•0 comments

Deadlines [pdf]

https://web.mit.edu/ariely/www/MIT/Papers/deadlines.pdf
1•ankitg12•1m ago•0 comments

DMARCbis Is Published: RFC 9989, 9990, and 9991 Replace RFC 7489

https://dmarcguard.io/blog/dmarc-rfc-9989-9990-9991/
1•meysamazad•2m ago•0 comments

Gemini Omni

https://blog.google/innovation-and-ai/models-and-research/gemini-models/gemini-omni/
1•theanonymousone•3m ago•0 comments

Hackers Reached GitHub's Internal Repositories Through a VS Code Extension

https://firethering.com/github-breach-vs-code-extension-attack/
1•steveharing1•4m ago•0 comments

AI Safety Is Underfunded by Design: Model for Incentive-Aligned AI Safety Policy

https://substack.norabble.com/p/ai-safety-is-underfunded-by-design
1•nedruod•5m ago•0 comments

GitHub: Incident with Actions

https://www.githubstatus.com/incidents/g6ffrm0rfvz9
2•nivekney•5m ago•0 comments

Show HN: IgniteMS – batch text embeddings at 253K msg/s on 8x A100

https://github.com/Artain-AI/ignite-ms
1•ddayanov•5m ago•0 comments

Privacy Shouldn't Be a Corporate Decision

https://www.eff.org/deeplinks/2026/05/your-privacy-shouldnt-be-corporate-decision
1•Brajeshwar•6m ago•0 comments

Green steel startup Boston Metal is doubling down on critical metals

https://www.technologyreview.com/2026/05/20/1137523/boston-metal-funding-critical-metals/
1•joozio•8m ago•0 comments

People writing about their use of AI

https://manuelmoreale.com/thoughts/on-people-writing-about-their-use-of-ai
2•speckx•8m ago•1 comments

Why English will never be a programming language

https://www.slater.dev/2026/05/why-english-will-never-be-a-programming-language/
2•sltr•9m ago•0 comments

Utah legislature to explore data centers' impacts

https://www.fox13now.com/news/politics/utah-legislature-to-explore-data-centers-impacts
2•cdrnsf•12m ago•0 comments

PreyReach – AI chat that pulls local-business leads live from Google Places

https://preyreach.com/
2•saeedmshadi•14m ago•1 comments

Bashiir

https://blog.cloudflare.com/post-quantum-warp/
1•bashiir•14m ago•0 comments

Entropy, relayed from real RTL-SDR hardware

https://sdrrand.nuts.services/
1•kordlessagain•15m ago•0 comments

I Don't Vibe Code

https://jacobharr.is/personal/i-dont-vibe-code
3•birdculture•16m ago•0 comments

Disney Faces $5M Lawsuit over Disneyland Facial Recognition

https://reclaimthenet.org/disney-faces-5m-lawsuit-over-disneyland-facial-recognition
3•Cider9986•16m ago•0 comments

Big Tech Backs Colorado OS-Level Age Data Bill

https://reclaimthenet.org/big-tech-backs-colorado-os-level-age-data-bill
2•Cider9986•16m ago•0 comments

Township Leader Resigns in Tears over OpenAI Data Center Death Threats

https://www.404media.co/township-leader-resigns-in-tears-over-openai-data-center-death-threats/
5•cdrnsf•17m ago•0 comments

After Town Bans Flock, Councilmember Crashes Out, Proposes Internet, Phone Ban

https://www.404media.co/after-town-bans-flock-councilmember-crashes-out-proposes-internet-and-pho...
11•cdrnsf•17m ago•2 comments

James Murdoch to Buy New York Magazine, Other Vox Assets for Around $300M

https://www.wsj.com/business/media/vox-media-selling-new-york-magazine-podcast-network-to-james-m...
2•Cider9986•18m ago•0 comments

Scaling Real-Time Traffic Forecasting with a Graph-Aware Transformer

https://www.uber.com/us/en/blog/scaling-real-time-traffic/
1•olcaycirit•19m ago•0 comments

Show HN: Dari-docs – Optimize your docs using parallel coding agents

https://github.com/mupt-ai/dari-docs
2•byhong03•19m ago•0 comments

The Great Token Wager

https://iainschmitt.com/post/tokens-and-taiwan
1•abnercoimbre•19m ago•0 comments

VSM Loop: Viable-System Orchestration for Multi-Agent R&D

https://github.com/7mind/nix-config/blob/main/pkg/llm-prompts/skills/vsm-loop/content.md
1•pshirshov•20m ago•1 comments

Exploit released for new PinTheft Arch Linux root escalation flaw

https://www.bleepingcomputer.com/news/linux/exploit-released-for-new-pintheft-arch-linux-root-esc...
1•Brajeshwar•20m ago•0 comments

Ask HN: Shouldn't Google need to give a public statement about Railway incident?

4•srameshc•21m ago•1 comments

Show HN: Prism Coder – Qwen3.5-14B fine-tuned for MCP tool-routing decisions

https://github.com/dcostenco/prism-coder
2•dcostenco4•22m ago•0 comments

Nobody Cares, Write Anyway

https://blog.absurdpirate.com/nobody-cares-write-anyway/
3•cyanbane•24m ago•0 comments