Subject: Re: cheap performance boost tip
To: None <port-arm32@netbsd.org>
From: Ross Harvey <ross@teraflop.com>
List: port-arm32
Date: 08/31/1998 10:33:40
Anyone who wants to know just how the MFS works need only read mfs_doio() in:
src/sys/ufs/mfs/mfs_vnops.c.
It's a grand total of only _8_ lines, and it does all the MFS I/O by just
calling copyin() or copyout() to the mount_mfs process.
And that process is just the newfs process: see line 172 in
src/sbin/newfs/mkfs.c
Which contains:
membase = malloc(fssize * sectorsize)
Yes, the entire MFS is just a thing returned by a user program calling
malloc(3). The blocks will be created as they are touched. They are never
released, but for the most part don't exist until used.
-- Ross Harvey