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?

How to Make Something People (Actually) Give a Shit About

https://www.joanwestenberg.com/p/how-to-make-something-people-actually
1•surprisetalk•20s ago•0 comments

The

https://worldwininternationaenter.blogspot.com/?m=1
1•Worldwin77•20s ago•0 comments

Simplified Technical English

https://en.wikipedia.org/wiki/Simplified_Technical_English
1•patrakov•36s ago•0 comments

How Polymarket Works and How to Backtest Prediction Strategies in Python

https://www.reddit.com/r/Polymarket/comments/1vedjgz/pythonbased_backtesting_for_polymarket_with_...
1•syumei•50s ago•0 comments

Show HN: Headroom – warns you before your AI chat starts forgetting

https://github.com/ZM-BAD/headroom
1•zm_bad•1m ago•0 comments

Series or Parallel: the fork that decides hybrid aviation

https://www.geaerospace.com/news/press-releases/ge-aerospace-partners-nasa-beta-technologies-and-...
1•r2sk5t•1m ago•0 comments

The Allure and Peril of Riding an Alaskan Wave for Six Miles

https://www.nytimes.com/2026/08/02/us/bore-tide-surfing-alaska.html
1•whack•1m ago•0 comments

Show HN: Swath – parallel S3 listing without knowing the key distribution

https://github.com/varveio/swath
1•sagiba•3m ago•1 comments

AI database chat: ask in plain language, review the query, get answers

https://plugins.jetbrains.com/plugin/33126-asksql
1•technoscripts•3m ago•0 comments

Transforms complex documents like PDFs and Office docs into Markdown/JSON

https://github.com/opendatalab/mineru
1•jacquesm•4m ago•0 comments

Putting AI Everywhere Does Not Mean Success

https://msakkal.com/research/ai-everywhere-not-success.html
2•MS8080•5m ago•0 comments

Engineers plan to save the satellite sent to save NASA's Swift mission

https://arstechnica.com/space/2026/08/heres-how-engineers-plan-to-save-the-satellite-sent-to-save...
2•LorenDB•6m ago•0 comments

MiniMax H3 Day-0 Support in ComfyUI: Open Weights, Native Audio, and 2K Video

https://blog.comfy.org/p/minimax-h3-day-0-support-in-comfyui
3•vblanco•6m ago•0 comments

SPF Record Syntax: Mechanisms, Qualifiers, Modifiers, and Macros

https://dmarcguard.io/blog/spf-record-syntax/
2•meysamazad•6m ago•0 comments

The Red Strings Club

https://www.vegard.net/the-red-strings-club-review/
1•meysamazad•6m ago•0 comments

GeoAI: Understanding the New Grammar

https://arkives.in/posts/07/2026/geoai-understanding-the-new-grammar/
1•meysamazad•7m ago•0 comments

Moths That Smell Flowers Through Their Wings

https://gizmodo.com/these-moths-smell-through-their-wings-study-finds-2000791478
1•gmays•7m ago•0 comments

Mastermind of a US Telemedicine Scam Is Enjoying the Luxury Life in Russia

https://istories.media/en/stories/2026/07/29/american-fraudsters-luxury-life-in-russia/
2•obscurette•7m ago•0 comments

SpaceX wins $1.6B Space Force contract for 18 Falcon 9 launches

https://spacenews.com/spacex-wins-1-6-billion-in-launch-orders-for-military-satellite-networks/
2•MarcoDewey•7m ago•0 comments

Godox Transparent Viewfinder Camera C100

https://www.godox.com/product-e/C100.html
2•routeroff•8m ago•0 comments

Agent needs a computer, not a container – introducing Cloudflare/computer

https://blog.cloudflare.com/cloudflare-computer/
1•aofeisheng•8m ago•0 comments

Show HN: An open source user feedback widget

https://www.feedchat.io/
1•visualbinary•9m ago•0 comments

Cloudflare Workers and Containers now support inbound TCP connections and gRPC

https://blog.cloudflare.com/grpc-workers/
1•aofeisheng•10m ago•0 comments

What Happens Inside a RAG Pipeline

https://deeptechrambles.substack.com/p/what-actually-happens-inside-a-rag
1•sd76•10m ago•0 comments

Frame selection is the whole game: notes on making LLMs watch video

https://leoaido.com/how-llms-watch-video/
1•cortexosmain•12m ago•0 comments

Pelles C

https://pellesc.se/
3•Tomte•14m ago•0 comments

Show HN: Having models make roller coasters instead of pelicans (via OpenRCT2)

https://coasterbench.wseaton.com/
1•Disp4tch•14m ago•0 comments

30 years of CPUs at Tom's Hardware – looking back on three decades of processors

https://www.tomshardware.com/pc-components/cpus/30-years-of-cpus-at-toms-hardware-looking-back-on...
3•speckx•14m ago•0 comments

Techie lured out of retirement to support software only he remembered

https://www.theregister.com/software/2026/07/31/techie-lured-out-of-retirement-to-support-softwar...
3•YeGoblynQueenne•15m ago•0 comments

Base4 – A New Base System for Visualizing Binary

https://github.com/peymanx/base4
1•peymanx•17m ago•0 comments