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

Comments

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

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

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

AI has the worst sales pitch I've ever seen

https://www.noahpinion.blog/p/ai-has-the-worst-sales-pitch-ive
2•ray__•1m ago•0 comments

Prompt Engineering Is Not. Engineering, That Is

https://the-infrastructure-mindset.ghost.io/prompt-engineering-is-not/
2•wphillipmoore•2m ago•0 comments

Creating new Python webframework –SlimeWeb

https://pypi.org/project/SlimeWeb/
1•Abilash_Suresh•3m ago•0 comments

New record: Laser for surgery cuts bone deeper than before

https://medicalxpress.com/news/2026-02-laser-surgery-bone-deeper.html
1•PaulHoule•3m ago•0 comments

Let's Standardize the 1970 Epoch

https://github.com/billpg/1970EpochalTime/
1•billpg•4m ago•0 comments

AI-Driven Offensive Security: The Current Landscape and What It Means

https://www.praetorian.com/blog/ai-driven-offensive-security/
1•tcbrah•4m ago•0 comments

Colorado River crisis: headwater states resist cuts, citing scarce supply

https://wyofile.com/amid-dire-situation-for-colorado-river-basin-headwater-states-say-they-cant-c...
1•toomuchtodo•5m ago•1 comments

NimbiCMS – a Markdown-first CMS for static servers

1•abel_vm•5m ago•0 comments

What's the biggest business you could run alone?

https://orischwartz.com/posts/whats-the-biggest-business-you-could-run-alone.html
1•fleaflicker•6m ago•0 comments

Intercom's model beats GPT 5.4 and Sonnet 4.6 at customer support resolutions

https://venturebeat.com/technology/intercoms-new-post-trained-fin-apex-1-0-beats-gpt-5-4-and-clau...
1•bscanlan•8m ago•0 comments

Refusal to Give the Govt Passwords to Personal Mobile Criminalized in Hong Kong

https://hk.usconsulate.gov/security-alert-2026032601/
1•jmsflknr•9m ago•0 comments

Development of 3D-printed chitosan/p-coumaric acid scaffolds for wound healing

https://www.sciencedirect.com/science/article/pii/S0939641125003315
1•PaulHoule•9m ago•0 comments

Gratitude Without God

https://www.theatlantic.com/health/archive/2014/11/the-phenomenology-of-gratitude/383174/
1•amadeuspagel•10m ago•2 comments

Show HN: I built AI agents that debate questions LLMs usually refuse to answer

https://factagora.com/
1•ttlcc13•11m ago•0 comments

Mojave Sequence: Website to generate personalized small business options

https://mojavesequence.base44.app
1•DesertMesa•11m ago•0 comments

Do you want to follow the Obsidian Kernel? Click here

https://github.com/roading-os/Obsidian-Kernel
2•oretuff•13m ago•0 comments

BPFdoor in Telecom Networks: Sleeper Cells in the Backbone

https://www.rapid7.com/blog/post/tr-bpfdoor-telecom-networks-sleeper-cells-threat-research-report/
2•speckx•13m ago•0 comments

Coca-Cola, Walmart outgoing CEOs cite AI in decisions to step down

https://www.cnbc.com/2026/03/26/coca-cola-james-quincey-walmart-doug-mcmillon-artificial-intellig...
2•kjhughes•13m ago•1 comments

OpenTelemetry Profiles Enters Public Alpha

https://opentelemetry.io/blog/2026/profiles-alpha/
2•tanelpoder•17m ago•0 comments

Gonon: Building a Clock with No Numerals

https://tonygaeta.com/perceptor/code/gonon
2•nullpath•17m ago•0 comments

AWStrology: What Star Sign Is Every AWS Service?

https://medium.com/@brookejamieson/awstrology-what-star-sign-is-every-aws-service-908c417e65a6
2•brookejamieson•17m ago•0 comments

Show HN: Micro – apps without ads, algorithms or tracking

https://micro.mu
2•asim•18m ago•0 comments

Arc Pudding – A scriptable compass and rule drawing tool

https://hlnet.neocities.org/arc-pudding/
2•maitland•18m ago•0 comments

Canaries in the Coal Mine? Six Facts about the Recent Employment Effects of AI [pdf]

https://digitaleconomy.stanford.edu/app/uploads/2025/11/CanariesintheCoalMine_Nov25.pdf
2•Vaslo•19m ago•0 comments

Are LLMs Reliable Code Reviewers?

https://arxiv.org/abs/2603.00539
2•PaulHoule•19m ago•0 comments

Show HN: An unstructured data workspace for data transformations with LLM

https://www.usefolio.ai/
2•nibab•20m ago•0 comments

US Postal Service to introduce 8% fuel surcharge on packages

https://www.theguardian.com/business/2026/mar/25/us-postal-service-fuel-surcharge
4•hypeatei•20m ago•0 comments

Intercom create a custom model for customer support

https://twitter.com/eoghan/status/2037197696075981124
2•bscanlan•20m ago•0 comments

Pitfalls to watch out for as your team adopts DORA's software delivery metrics

https://dora.dev/guides/dora-metrics/#common-pitfalls
2•mooreds•21m ago•0 comments

Judge dismisses lawsuit by Musk's X Corp accusing advertisers of illegal boycott

https://www.reuters.com/world/judge-dismisses-lawsuit-by-musks-x-corp-accusing-advertisers-illega...
6•babelfish•22m ago•0 comments