Date: Fri, 7 May 2004 01:30:27 +1000 (EST) From: Bruce Evans <bde@zeta.org.au> To: Alan Cox <alc@FreeBSD.org> Cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/fs/nwfs nwfs_io.c src/sys/fs/smbfssmbfs_io.c src/sys/fs/specfs spec_vnops.c src/sys/kern uipc_syscalls.c vfs_bio.c src/sys/nfsclient nfs_bio.c src/sys/vm swap_page Message-ID: <20040507010151.I21163@gamplex.bde.org> In-Reply-To: <200405060503.i4653OfT061105@repoman.freebsd.org> References: <200405060503.i4653OfT061105@repoman.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 5 May 2004, Alan Cox wrote:
> alc 2004/05/05 22:03:24 PDT
>
> FreeBSD src repository
>
> Modified files:
> sys/fs/nwfs nwfs_io.c
> sys/fs/smbfs smbfs_io.c
> sys/fs/specfs spec_vnops.c
> sys/kern uipc_syscalls.c vfs_bio.c
> sys/nfsclient nfs_bio.c
> sys/vm swap_pager.c vm_fault.c vnode_pager.c
> Log:
> Make vm_page's PG_ZERO flag immutable between the time of the page's
> allocation and deallocation. This flag's principal use is shortly after
> allocation. For such cases, clearing the flag is pointless. The only
> unusual use of PG_ZERO is in vfs_bio_clrbuf(). However, allocbuf() never
> requests a prezeroed page. So, vfs_bio_clrbuf() never sees a prezeroed
^^^^^ rarely(?)
> page.
>
> Reviewed by: tegge@
The request for a prezeroed page is just a preference, so vfs_bio_clrbuf()
certainly gets prezeroed pages. This happens whenever there are only
prezeroed pages to find. I think vfs_bio_clrbuf() sees them too. It
saw them at least once a few years ago when my debugging code for this
finally triggered. My kernel at the time had colorizing optimizations
that probably made using a prezeroed page more likely.
The PG_ZERO optimizations in vfs_bio_clrbuf() were just worse than useless
because they rarely applied (and they break immutability here).
Bruce
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040507010151.I21163>
