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?

Yet Another OpenCode Plugin

https://npmjs.com/package/yet-another-opencode-plugin
1•smokeeaasd•49s ago•0 comments

Fiddler Classic Changes License: Noncommercial Use Only, 45 Days to Comply

https://www.telerik.com/purchase/license-agreement/fiddler
1•tech234a•1m ago•0 comments

Cloudflare Wallets: the programmable wallet for the agentic Internet

https://blog.cloudflare.com/wallets/
1•hahahaa•1m ago•0 comments

3D Printing Agentic Automation

https://praveenvijayan.substack.com/p/3d-print-automation-text-a-link-get
1•praveenvijayan•3m ago•0 comments

Ask HN: Dear Anthropic, can we please have thought traces back?

1•exabrial•4m ago•0 comments

Where the Automation Has to Stop

https://yusufaytas.com/where-the-automation-has-to-stop
7•montrealish•4m ago•0 comments

The 'dean of valuation' says pain is headed for more AI companies soon

https://www.businessinsider.com/ai-stock-market-correction-dean-of-valuation-aswath-damodaran-2026-8
1•mapping365•5m ago•0 comments

Personal computer is not that personal

https://prahaladhchandrahasan.github.io/thoughts/your-personal-computer-is-not-that-personal/
1•pdawg0518•6m ago•0 comments

Uber's Autonomous Vehicle Strategy: Slow Their Adoption

https://www.wired.com/story/ubers-autonomous-vehicle-strategy-slow-their-adoption/
1•dmitriy_ko•9m ago•0 comments

Should designers publicly share killed or speculative work?

https://benbarry.com/writing/should-designers-publicly-share-killed-or-speculative-work
1•herbertl•10m ago•0 comments

S

2•Sidhant_ch•11m ago•1 comments

Show HN: A search engine for VPS servers with an automatic crawler pipeline

https://vpspricetracker.com
1•davidebaldini•12m ago•0 comments

Codes, Chess and Kubrick: The Life of Jack Good – GCHQ

https://www.gchq.gov.uk/information/codes-chess-and-kubrick-life-jack-good
1•rbanffy•13m ago•0 comments

Data centers have a politics problem

https://www.politico.com/news/2026/08/01/data-centers-have-a-politics-problem-and-industry-knows-...
1•mapping365•13m ago•0 comments

Success of New Federal Housing Law Rests on States and Localities

https://ifp.org/the-success-of-the-new-federal-housing-law-now-rests-on-states-and-localities/
3•atlasunshrugged•13m ago•0 comments

Count Binface: Britain's 'joke' election candidates should be taken seriously

https://theconversation.com/count-binface-why-britains-joke-election-candidates-deserve-to-be-tak...
3•samizdis•14m ago•0 comments

Resistance grows nationwide against AI data center boom

https://www.cbsnews.com/video/resistance-grows-nationwide-against-ai-data-center-boom/
4•mapping365•14m ago•0 comments

An AI voice agent running locally on a $50 Arduino uno Q

https://projecthub.arduino.cc/neelbuilds/build-a-voice-based-kiosk-for-retail-store-using-moorche...
3•supportm•14m ago•0 comments

Could You Still Be "You" Without a Single Memory?

https://comuniq.xyz/post?t=1501
1•01-_-•14m ago•0 comments

Show HN: Mcpscore – validate any MCP server compliance with a new MCP version

https://github.com/mcp-box/mcpscore
1•alex_akimov•14m ago•0 comments

Atomic Vibe Coding

https://unengineered.substack.com/p/atomic-vibe-coding
1•josharsh•17m ago•2 comments

GPT-5.6 fuses frontier intelligence with frontier efficiency

https://openai.com/index/gpt-5-6-frontier-intelligence-efficiency/
1•gmays•17m ago•0 comments

How the Sony Walkman Failed to Destroy Civilization

https://www.tokyoweekender.com/entertainment/tech-trends/sony-walkman-history-moral-panic/
2•ecliptik•17m ago•0 comments

Tokenpolitik: The new geopolitics of artificial intelligence

https://decode39.com/16003/tokenpolitik-the-new-geopolitics-of-artificial-intelligence/
2•huna_huna•17m ago•0 comments

Third-party cyber evaluations involving OpenAI models

https://openai.com/index/third-party-cyber-evaluations-involving-openai-models/
2•glub•18m ago•0 comments

Oxide RFD 284: Loading the Host Operating System

https://rfd.shared.oxide.computer/rfd/0284
2•tosh•18m ago•1 comments

Ask HN: What if there was an 8th day of the week?

2•cyanregiment•19m ago•0 comments

The Budget Behind Your Favorite Songs

https://monictheory.com/articles/the-hidden-budget-behind-your-favorite-songs
1•song_synth•19m ago•0 comments

Incident Report: unsanctioned agent behaviour during cyber testing

https://www.aisi.gov.uk/blog/incident-report-unsanctioned-agent-behaviour-during-cyber-testing
2•Philpax•19m ago•0 comments

Japan's superior alternative to Paxlovid called Xocova, finally available in US

https://www.shionogi.com/global/en/news/2026/07/20260729.html
3•ck2•20m ago•1 comments