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•8mo ago

Comments

nine_k•8mo 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•8mo ago
We are always reinventing wheels. If we didn't, they'd all still be made of wood.
Zolomon•8mo ago
They mention this in the article.
spockz•8mo ago
It reminds me more of flat buffers though. Does protobuf also have zero allocation (beyond initial ingestion) and no pointer jumps?
cstrahan•8mo ago
No, one example of why being variable sized integers.

See https://protobuf.dev/programming-guides/encoding/

carterschonwald•8mo ago
One thing that sometimes gets tricky in these things is handling Sub term sharing. I wonder how they implemented it.
tlb•8mo 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•8mo 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•8mo 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•8mo ago
honestly i wish more stuff worked this way - fewer hops in memory always makes me happy
lordleft•8mo ago
This was very well written. Excellent article!
NetOpWibby•8mo ago
Is this like MessagePack for Haskell?

Behind Trump vs. Powell Is a Battle over US Empire's Future

https://jacobin.com/2026/01/trump-powell-fed-europe-dollars
1•kaycebasques•2m ago•0 comments

It Can Apply and Positive in Favor the Newton III Law on an Engine System Device

1•monterrey•5m ago•0 comments

State Ofthe Art Novel InFlow 1Gearturbine/Reaction 2Imploturbocompressor/Impulse

1•monterrey•7m ago•0 comments

San Francisco to offer free childcare to people making up to $230000

https://www.theguardian.com/us-news/2026/jan/15/san-francisco-childcare-families
1•darth_avocado•8m ago•0 comments

Podcasting Could Use a Good Asteroid

https://www.joanwestenberg.com/podcasting-could-use-a-good-asteroid/
1•zdw•10m ago•0 comments

Ask HN: What are Claude's skills/what skills does Claude possess?

1•Obscurity4340•11m ago•0 comments

Glyphhanger – Your web font utility belt

https://www.zachleat.com/web/glyphhanger/
1•doodlesdev•13m ago•0 comments

The Myth of the ThinkPad

https://innovintageblog.wordpress.com/2026/01/08/the-myth-of-the-thinkpad/
1•volemo•15m ago•2 comments

Jeff Bezos Needs to Speak Up

https://www.theatlantic.com/ideas/2026/01/raid-washington-post/685621/
1•JumpCrisscross•16m ago•1 comments

Ericsson Silent Layoffs in the US

2•allabouttech•20m ago•1 comments

Trump Moves to Make Tech Giants Pay for Surging Power Costs

https://www.bloomberg.com/news/articles/2026-01-15/trump-to-direct-key-us-grid-operator-to-hold-e...
2•jmcdonald-ut•20m ago•1 comments

America's Throwaway Spies: How the CIA Failed Iranian Informants in Tehran

https://www.reuters.com/investigates/special-report/usa-spies-iran/
2•koolhead17•22m ago•0 comments

Mark Carney and Xi Jinping meet to mend ties as Donald Trump disrupts globe

https://www.ft.com/content/9eeff245-2081-4f97-bc8e-6bbdaf59074e
3•KnuthIsGod•24m ago•0 comments

Fontello – Combine icon webfonts for your own project

https://github.com/fontello/fontello
1•doodlesdev•25m ago•0 comments

Is there any way we can help Stack Overflow Website get back up?

https://stackoverflow.com/questions/79867766/is-there-any-way-we-can-help-stack-overflow-website-...
1•nomilk•25m ago•0 comments

AI as a Compression Problem

https://dkg.fifthhorseman.net/blog/2025-ai-and-compression.html
1•pabs3•26m ago•0 comments

PanoptiCity – interactive map reveals the scale of mass surveillance worldwide

https://panopticity.fr/
2•pabs3•27m ago•0 comments

How Safe Is the Rust Ecosystem? A Deep Dive into Crates.io

https://mr-leshiy-blog.web.app/blog/crates_io_analysis/
1•RustSupremacist•32m ago•0 comments

Trump accepts Nobel Peace medal from Venezuelan opposition leader

https://www.smh.com.au/world/north-america/venezuelan-opposition-leader-says-she-presented-trump-...
2•KnuthIsGod•32m ago•2 comments

Gen X and Millennials Will Inherit Trillions in Real Estate over the Next Decade

https://www.wsj.com/real-estate/luxury-homes/millennial-genx-inherit-real-estate-wealth-d78b4454
2•alephnerd•37m ago•1 comments

From AI agent prototype to product: Lessons from building AWS DevOps Agent

https://aws.amazon.com/blogs/devops/from-ai-agent-prototype-to-product-lessons-from-building-aws-...
1•malahay•41m ago•1 comments

TranslateGemma: A new suite of open translation models

https://blog.google/innovation-and-ai/technology/developers-tools/translategemma/
2•anigbrowl•41m ago•0 comments

Show HN: Buildzr: Python DSL for Authoring C4 Models

https://github.com/amirulmenjeni/buildzr
1•amenji•43m ago•0 comments

Apple's Tactics Could Prevent Japan from Improving Browser Competition

https://open-web-advocacy.org/blog/how_apples_key_tactic_could_prevent_japans_smartphone_act_from...
1•donohoe•46m ago•0 comments

Boeing knew of flaw in part linked to UPS plane crash

https://www.bbc.com/news/articles/cly56w0p9e1o
31•1659447091•49m ago•5 comments

Microsoft Xbox Manufacturing in 2002

https://www.youtube.com/watch?v=YeQrQYFVlXA
1•guidedlight•51m ago•0 comments

Image FX – Free One-Click AI Photo Editor and Image Generator

https://image-fx.app
1•julian2026•51m ago•0 comments

European Alternatives for Digital Products

https://european-alternatives.eu
1•memset•53m ago•0 comments

Show HN: Dev Utility Hub – Client-side only developer tools (JSON, JWT, Cron)

1•hun-ing•56m ago•0 comments

vLLM-MLX – Run LLMs on Mac at 464 tok/s

https://github.com/waybarrios/vllm-mlx
2•waybarrios•1h ago•1 comments