From owner-cvs-sys Tue Jan 6 00:02:54 1998 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id AAA14412 for cvs-sys-outgoing; Tue, 6 Jan 1998 00:02:54 -0800 (PST) (envelope-from owner-cvs-sys) Received: from dyson.iquest.net (dyson.iquest.net [198.70.144.127]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id XAA14036; Mon, 5 Jan 1998 23:57:08 -0800 (PST) (envelope-from toor@dyson.iquest.net) Received: (from root@localhost) by dyson.iquest.net (8.8.8/8.8.8) id CAA05511; Tue, 6 Jan 1998 02:56:55 -0500 (EST) (envelope-from toor) From: "John S. Dyson" Message-Id: <199801060756.CAA05511@dyson.iquest.net> Subject: Re: John's latest VM commit. In-Reply-To: from Julian Elischer at "Jan 5, 98 11:37:05 pm" To: julian@whistle.com (Julian Elischer) Date: Tue, 6 Jan 1998 02:56:55 -0500 (EST) Cc: dyson@freebsd.org, cvs-committers@freebsd.org, cvs-all@freebsd.org, cvs-sys@freebsd.org X-Mailer: ELM [version 2.4ME+ PL31 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-cvs-sys@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Julian Elischer said: > > Kirk told me a few years ago that he was seriously considering merging the > vm-object and vnode strucures so that one BECAME the other. Is this a > stupid idea? > I don't think that it is a stupid idea. > > In his estimation, they contained many of the same fiedls which simply > meant duplication of information, an danother place where things could get > out of sync. Of course this was 5 years ago so you may already have > removed much of the duplication. > The vnode and VM object are actually two different things. VM objects are items of memory. The vnode represents the filesystem's view of one type of VM object. Note that vnodes have lists of buffers associated with them, and VM objects have pages associated with them. Buffers are (should be) there for I/O and temporary mappings (when needed.) Pages associated with objects are for caching. Actually, I would like to see us do away with buffers, except as an I/O abstraction. The vnodes are specific to a type of secondary storage object, but do not represent a memory object. It would probably be a good thing to make all caching in our system VM object based. Then buffers will degrade into a structure used to communicate with I/O devices. I would not like to see the terrible mess that SVR4 has, with various types of vnode like structures in order to represent swap, filesystem, device files. Eventually, as we can deprecate the use of buffer's as a metadata cache, I think that our buffers will be able to be abstracted as I/O requests, as they should be. Then, the more general VM objects will be the primary (only) caching mechanism. -- John | Never try to teach a pig to sing, dyson@freebsd.org | it just makes you look stupid, jdyson@nc.com | and it irritates the pig.