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?

Lybrary,a persistent AST-aware code memory for AI agents(MCP server pip install)

https://github.com/vibhu-dixit/lybrary
1•vibhudixit_30•3m ago•0 comments

Show HN: Agent_acid – ACID rollbacks and dry-run guardrails for AI agents

https://github.com/muhammadwaqasai/agent_acid
1•waqasai123•4m ago•0 comments

I'm Begging You: Never Write with A.I

https://www.nytimes.com/2026/08/04/opinion/artificial-intelligence-ai-writing.html
2•edward•5m ago•0 comments

Cross platform, portable and CPU accelerated AI inference with Go 1.27

https://blog.devgenius.io/achieving-local-ai-inference-with-go-1-27s-simd-package-e8875f567e35?sk...
1•cheikhdev•10m ago•0 comments

WebDuck – DuckDB as a Service

https://webduck.autumo.ch/
2•jonbaer•25m ago•0 comments

Does Silicon Valley Dream of Philip K Dick?

https://www.ft.com/content/bdcf7729-3b03-49ec-82fb-b5773fdaa990
1•mraniki•26m ago•0 comments

xAI launches Imagine Image 2.0 for production image workflows

https://runtimewire.com/article/xai-imagine-image-2-precision-editing-production-workflows
1•ryanmerket•26m ago•0 comments

JEDEC releases new SPHBM4 standard to slash AI memory costs – 512-bit interface

https://www.tomshardware.com/pc-components/dram/jedec-releases-new-sphbm4-standard-to-slash-ai-me...
1•peter_d_sherman•37m ago•0 comments

The Genesis Mission: AI and Quantum-Driven Discovery

https://github.com/donutloop/donutloop-genesis/blob/main/README.md
1•donutloop•37m ago•0 comments

The ultimate horse

https://worksinprogress.co/issue/the-ultimate-horse/
2•zdw•41m ago•0 comments

Samsung debuts three new memory technologies – zHBM, zNAND-O, and BV-NAND

https://www.tomshardware.com/pc-components/dram/samsung-debuts-three-next-generation-memory-techn...
2•peter_d_sherman•42m ago•0 comments

I'm Sorry, Dave

https://world.hey.com/dhh/i-m-sorry-dave-380ec27d
1•ciconia•47m ago•0 comments

Supersonic Trebuchet [video]

https://www.youtube.com/watch?v=Co57SfcT-h0
1•fortran77•52m ago•0 comments

Facing 474 GW of interconnection requests, Texas hits pause on data centers

https://www.utilitydive.com/news/texas-hits-pause-data-center-interconnections/827046/
2•geox•57m ago•0 comments

AI on a Piece of Sponge?

https://driftspeed.wordpress.com/2026/08/07/ai-on-a-piece-of-sponge/
1•harhargange•59m ago•1 comments

OpenAI Trained Models for Months While Those Models Were Coordinating Exploits

https://thezvi.substack.com/p/openai-trained-its-models-for-months
3•paulpauper•1h ago•0 comments

Etherpad – the editor for documents that matter

https://etherpad.org/
3•treetalker•1h ago•0 comments

Neutrinos from Deep Inside Earth Provide a New Picture of the Mantle

https://www.quantamagazine.org/neutrinos-from-deep-inside-earth-provide-a-new-picture-of-the-mant...
1•jnord•1h ago•0 comments

Mr. Balaji Goes to Kazakhstan

https://www.labormarketmatters.com/p/mr-balaji-goes-to-kazakhstan
1•paulpauper•1h ago•0 comments

He Had Tenure. The New School Laid Him Off Anyway

https://www.nytimes.com/2026/08/05/nyregion/new-school-faculty-fired-nyc.html
3•paulpauper•1h ago•0 comments

Mythos social engineering AISI INC-2026-07-28-01

https://web.archive.org/web/20260731053721/http://github.com/ancaferro/myNetwork/pull/3
30•dnnehgf•1h ago•13 comments

SECSift – Read, search, compare, and analyze any SEC filing

https://secsift.com
1•Fajasy•1h ago•0 comments

Show HN: Utter – Turn your voice to automatic To-dos. No sign-up

https://play.google.com/store/apps/details?id=com.utter.app&hl=en_US
1•Vellan77•1h ago•1 comments

Traditions are habits somebody else paid for

https://pilgrima.ge/p/full-price
2•momentmaker•1h ago•1 comments

cpuscout.com Is Down

https://www.cpuscout.com/
1•RemingtonDavies•1h ago•0 comments

Show HN: Finding obfuscated GitHub PATs and API keys in large repos

https://medium.com/@hanikhaled876/how-i-found-hardcoded-secrets-in-facebooks-react-repository-ed7...
2•SENTINEL_888•1h ago•0 comments

Universality and diversity in human song (2019)

https://www.science.org/doi/10.1126/science.aax0868
2•Ariarule•1h ago•0 comments

Show HN: Buddy – An iOS browser with an AI agent inside

https://apps.apple.com/us/app/buddy-the-ai-mobile-browser/id6788047483
3•guribe94•1h ago•1 comments

Twelve Years in the Making: JDK 28 Ships Value Classes Preview

https://sudosecurity.org/jdk-28-feature-preview/
1•SudoSH•1h ago•0 comments

Etherpad: A multi-touch synthesizer for iOS and Android

https://etherpad.app
1•zebproj•1h ago•0 comments