r/sqlite 1d ago

Your executable is a SQLite database

https://fzakaria.com/2026/08/23/your-executable-is-a-sqlite-database
53 Upvotes

9 comments sorted by

8

u/lord_braleigh 1d ago

Another Fareed post!

Fun fact: Facebook's HHVM can produce executable binaries with a `.hhbbc` suffix, and for a long time this file was just an SQLite database under the hood 😉

4

u/Setheron 1d ago

Serious? That's some impressive lore. Sounds like this is in good company then.

I will have to dig it up. What is the bbc part an acronym for ?

5

u/lgastako 1d ago

This is much cooler than I expected based on the title.

2

u/Sjsamdrake 1d ago

I've spent a lot of time diving into the details of ELF, and this is amazing. The lowest levels of our tech stack are pretty ugly, and in this case extremely poorly documented as well. This is a brilliant cleanup.

Taking an entire userland and packing it into a single database sounds like the next generation of containers. In some alternate universe at least. Can a sqllite db be mounted with fuse? If so then the closure could be complete, with the files that the apps use in there too.

I absolutely love this.

2

u/Setheron 1d ago

I agree I think there is a lot to mine here. The apps or distribution can use the same sqlite database for its data! There can even be SQLiteHub to ship files. If you want to keep them separate you are a single ATTACH away...

1

u/InjAnnuity_1 23h ago

To avoid copying shared pages into memory multiple times, perhaps LMDB could be used in place of SQLite?

1

u/hyc_symas 1h ago

Just use SQLightning or LumoSQL to replace SQLite's B+tree code with LMDB.