On Feb 10, 2026, at 2:13 AM, Alyssa M via 9fans <[email protected]> wrote: > > On Monday, February 09, 2026, at 3:24 PM, ron minnich wrote: >> as for mmap, there's already a defacto mmap happening for executables. They >> are not read into memory. In fact, the first instruction you run in a binary >> results in a page fault. > I thinking one could bring the same transparent/defacto memory mapping to > read(2) and write(2), so the API need not change at all.
If you mean transparently mapping page aligned read/write, it can get messy. For reads you'd have to fix up page tables to fault on access for every page that is not yet read in. For writes you'd have to do copy-on-write in case the user tried to modify buffer passed to write(), until the old data is written out. This buys you reduced latency to first use at the expense of more kernel complexity. ------------------------------------------ 9fans: 9fans Permalink: https://9fans.topicbox.com/groups/9fans/Te8d7c6e48b5c075b-Me6107462bbd77fd08c2eb21e Delivery options: https://9fans.topicbox.com/groups/9fans/subscription
