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?

Show HN: Disclosure Lookup – a Caido plugin that finds where to report a vuln

https://github.com/disclose/caido-lookup
1•caseyjohnellis•4m ago•0 comments

There's a Global Network of Fungi Under Your Feet This Is the First Complete Map

https://www.wired.com/story/theres-a-global-network-of-fungi-under-your-feet-this-is-the-first-co...
1•Jimmc414•8m ago•1 comments

Apple updates vended agent skills: Xcode 27 Beta 3

https://petegoldsmith.com/blog/2026-07-07-xcode-27-beta-3-agent-skills/
2•theraven•9m ago•0 comments

A Sad Kind of Convenience - The death of physical media

https://www.theatlantic.com/technology/2026/07/playstation-ends-discs/687770/
1•Bondi_Blue•9m ago•1 comments

Show HN: Lingbot Vision – Self-Supervised Dense Perception (0.296 NYUv2 RMSE)

https://technology.robbyant.com/lingbot-vision
1•Kajaking•9m ago•0 comments

Balancing Claude 4.8 with GLM 5.2 in mid-level Coding Agent structuring prompts

https://cimons.com/article/balancing-claude-with-glm-5-2-in-mid-level-coding-agent-structuring-pr...
1•etcimon•9m ago•1 comments

Snap sued by parents of girl who was raped by man she met on Snapchat

https://www.latimes.com/business/story/2026-06-25/snap-sued-by-parents-of-girl-who-was-raped-by-m...
2•1vuio0pswjnm7•9m ago•0 comments

CapTablex: Open-source cap table managment in Elixir

https://github.com/captablex/captablex
1•rayrrr•17m ago•1 comments

A Mom Said Infant Formula Killed Her Baby. The Manufacturer Closed the File

https://kffhealthnews.org/health-industry/infant-formula-adverse-events-nec-baby-deaths-fda-repor...
1•Jimmc414•18m ago•0 comments

U.S. vs. Live Nation: Proposed Final Judgment and Competitive Impact Statement

https://www.federalregister.gov/documents/2026/07/06/2026-13623/united-states-et-al-v-live-nation...
1•Jimmc414•19m ago•0 comments

Show HN: My 11 year old daughter and I build this DQ8 style game on macOS

https://code.intellios.ai/cedricsquest/
1•coolwulf•20m ago•1 comments

PyPI Downloads accuracy

https://pepy.tech/projects/finops-mcp
1•chaandannn•20m ago•0 comments

Atlanta-based company saved $100k by replacing Salesforce with Replit-built CRM

https://twitter.com/amasad/status/2074274666709987663
1•backlit4034•20m ago•1 comments

Xbox cuts 3,200 jobs as gaming business struggles

https://www.latimes.com/entertainment-arts/business/story/2026-07-06/xbox-cuts-3-200-jobs-as-part...
1•1vuio0pswjnm7•26m ago•0 comments

A field guide to Claude Fable 5: Finding your unknowns

https://claude.com/blog/a-field-guide-to-claude-fable-finding-your-unknowns
1•geoffbp•27m ago•0 comments

AI's Volatile Power Use Tests Grid Limits

https://spectrum.ieee.org/data-centers-grid-instability
1•pseudolus•27m ago•0 comments

Microsoft's Xbox to Cut 3,200 Jobs, Divest Five Studios in Major Overhaul

https://www.bloomberg.com/news/articles/2026-07-06/microsoft-s-xbox-to-cut-3-200-jobs-divest-five...
1•1vuio0pswjnm7•30m ago•0 comments

Llamas on the Web

https://reeselevine.github.io/llamas-on-the-web/
1•thesimpleone•41m ago•0 comments

DARPA program to make 30 yr batteries for drones from nuclear waste

https://www.defenseone.com/technology/2026/07/these-light-weight-power-cells-run-nuclear-waste-an...
2•Gaishan•42m ago•0 comments

Why "a nice place to work" doesn't just happen

https://twitter.com/nithin0dha/status/2074098865511563473
2•dsr12•44m ago•0 comments

Unis are relying on AI-detection software to catch cheating. Does it work

https://www.nature.com/articles/d41586-026-01358-2
2•gnabgib•50m ago•1 comments

Amor Fati Entropy

https://hollisrobbinsanecdotal.substack.com/p/amor-fati-entropy
1•HR01•50m ago•0 comments

Show HN: Sel – macOS screen sharing that shows only the windows you pick

https://sel.toron.dev
1•ariaghora•56m ago•1 comments

Custom coreboot firmware (and utilities) for your Chromebook/Chromebox

https://docs.mrchromebox.tech/
1•lwhsiao•57m ago•0 comments

Karpathy, Google, Tan agree Markdown is the answer, but not for the same problem

https://thenewstack.io/markdown-agent-memory-moat/
2•theanonymousone•59m ago•0 comments

How to Design a Cancer Vaccine

https://www.owlposting.com/p/how-to-design-a-cancer-vaccine-and
4•iskander•1h ago•0 comments

Undertuber YouTube Underground Search Engine

https://github.com/BooleanMuse/Undertuber-Underground-Youtube-Search-Engine
4•skarmuse•1h ago•1 comments

The footgun of right-to-left decorative characters

https://blog.alexbeals.com/posts/the-footgun-of-right-to-left-decorative-characters
1•dado3212•1h ago•0 comments

Key Study: Social status and stress in Olive Baboons (1990)

https://www.themantic-education.com/ibpsych/2020/10/08/key-study-social-status-and-stress-in-oliv...
1•curmudgeon22•1h ago•0 comments

Agent-Assisted SGLang Development: An Initial Exploration

https://www.lmsys.org/blog/2026-07-02-agent-assisted-sglang-development/
1•gmays•1h ago•0 comments