News for hackers. Stuff that matters.
Re:Ask HN: Why serialize documents to disk instead of memory... by mac3n on Tuesday September 15, 2026 @08:41PM (#49720753)
Be careful!

I hear the old Microsoft Word save files used memory dumps, which became an undocumented nightmare of a file format.

You need total control over memory layout of the saved runtime state. No hidden fields. No pointers either - you want to be able to reload at another address. Sooner or later, you might want to add some state, and you'd need a place to put it.

That said, I have used mmap something like this, mostly so state (data) could be paged in on demand.

There are no comments on this comment yet.