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?

Latency Numbers Every Programmer Should Know (Over Time)

https://colin-scott.github.io/personal_website/research/interactive_latency.html
1•tosh•1m ago•0 comments

The China That Deng Built

https://coolestdog18.substack.com/p/the-china-that-deng-built
1•taiwandongsuan•1m ago•0 comments

What Is "Slop," Exactly?

https://maxread.substack.com/p/what-is-slop-exactly
1•jruohonen•3m ago•0 comments

Show HN: Loomind – Local-first chat with docs. Offline, Electron+Next.js

1•redhotcookerr•4m ago•0 comments

Creating virtual block devices with ublk

https://jpospisil.com/posts/2026-01-13-creating-virtual-block-devices-with-ublk
1•todsacerdoti•5m ago•0 comments

Honey's Dieselgate: Detecting and Tricking Testers (2025)

https://www.benedelman.org/honey-detecting-testers/
1•redbell•5m ago•0 comments

Show HN: PromptDuty-block leaking confidential data to ChatGPT

https://promptduty.com/
1•aleks5678•5m ago•0 comments

Show HN: Loomind – Local-first chat with docs. Offline, Electron+Next.js

https://loomind.me
1•redhotcookerr•7m ago•0 comments

Agent skills for your AWS/GCP cloud

https://github.com/encoredev/skills
1•dohguy•7m ago•0 comments

After mass-scraping, Meta is hiding follower lists of Iran-based Instagram users

https://www.threads.com/@wongmjane/post/DTqoLj8Ek0o/update-meta-is-now-hiding-the-following-follo...
1•baxtr•7m ago•0 comments

You Would Be a Terrible Leader (CGP Grey) [video]

https://www.youtube.com/watch?v=rStL7niR7gs
1•Imustaskforhelp•8m ago•0 comments

Artificial intelligence blame for video-game industry layoffs may be misguided

https://financialpost.com/news/artificial-intelligence-blame-for-layoffs-misguided
1•cumo•9m ago•0 comments

Space Force ends 'Resilient GPS' satellite program

https://spacenews.com/space-force-ends-resilient-gps-satellite-program/
1•defrost•10m ago•0 comments

Cara Menonaktifkan Akun Shopee [Spinjam] & Menghapus Akun SPinjam Shopee-Pinjam

1•begundal•11m ago•0 comments

Ask your Slack bot what the dev team shipped

2•inferno22•14m ago•0 comments

Building a Google Places Extraction Tool That Scales

https://blog.domharvest.dev/posts/building-a-google-places-extraction-tool-that-actually-scales/
2•DomHarvest•17m ago•1 comments

The Education of the Broligarchy

https://colossus.com/article/education-broligarchy-silicon-valley-canon/
1•jger15•17m ago•0 comments

I refused to invest in Tesla for years – but now's the time to bet on Elon Musk

https://www.marketwatch.com/story/i-refused-to-invest-in-tesla-for-years-but-nows-the-time-to-bet...
2•RickJWagner•17m ago•0 comments

Docker build –no-cache uses cache anyway

https://github.com/docker/buildx/issues/2387
1•bovem•18m ago•0 comments

Why the US is buying icebreakers from Finland

https://www.bbc.co.uk/news/articles/c0q48d71ke8o
1•n1b0m•19m ago•0 comments

Resistive vs. Reactive Growth Impedance

https://www.withbloom.ai/two-pagers/product-market-impedance
1•itsfseven•20m ago•0 comments

Product Marketing as Software Architecture: A Guide for Technical Founders

https://open.substack.com/pub/sobolev/p/product-marketing-as-software-architecture
1•alexsobolev•20m ago•0 comments

How tech billionaires spurred an exodus from California

https://www.washingtonpost.com/technology/2026/01/19/california-wealth-tax-exodus/
1•pseudolus•21m ago•2 comments

Please stop saying "Stochastic Parrot" – it is just plain wrong

https://bigthink.com/the-present/do-ai-models-reason-or-regurgitate/
2•hogwash•23m ago•1 comments

X Image Splitter (Tap the Post Tool) – split one image into 2 or 4 tiles locally

https://splitimage.im/x-image-splitter/
1•wangxin199•23m ago•2 comments

Just because Linus Torvalds vibe codes doesn't mean it's a good idea

https://www.theregister.com/2026/01/16/linus_torvalds_vibe_coding/?td=rt-3a
5•pseudolus•24m ago•0 comments

Tech Billionaires want us Dead – Taylor Lorenz [video]

https://www.youtube.com/watch?v=W1dIC287Zz0
1•pcthrowaway•24m ago•0 comments

I gave up on publishing my CLI tool to a PPA

1•saberd•25m ago•0 comments

Developer Basics: The Minimum You Need to Build with AI

https://makershub.dev/learn/roadmaps/developer-basics-the-minimum-you-need-to-build-with-ai
2•adilmoujahid•28m ago•0 comments

cURL stopped HackerOne bug bounty program due to excessive slop reports

https://github.com/curl/curl/pull/20312
6•latexr•29m ago•2 comments