From: Nick Piggin Subject: Re: Tux3 report: Tux3 Git tree available Date: Mon, 16 Mar 2009 21:14:13 +1100 Message-ID: <200903162114.14460.nickpiggin@yahoo.com.au> References: <200903110925.37614.phillips@phunq.net> <20090316051211.GB26138@disturbed> <20090316063830.GC6357@mit.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: linux-fsdevel@vger.kernel.org, tux3@tux3.org, Andrew Morton , linux-kernel@vger.kernel.org, Daniel Phillips To: Theodore Tso Return-path: In-Reply-To: <20090316063830.GC6357@mit.edu> Content-Disposition: inline List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: tux3-bounces@tux3.org Errors-To: tux3-bounces@tux3.org List-Id: linux-fsdevel.vger.kernel.org On Monday 16 March 2009 17:38:30 Theodore Tso wrote: > Dave, > > It wasn't my intention to say that XFS was bad; in fact, I thought I > was actually complementing XFS by talking about some of the advanced > features that XFS had (many of which I have always said that ext3 has, > and some of which ext4 still does not have, and probably never will > have). I stand corrected on some of the details that I got wrong. > What I was trying to say was that *if* (and perhaps I'm > misunderstanding fsblock) that fsblock is requiring that as soon as a > page is dirty, fsblock requests the filesystem to assign a block > allocation to the buffers attached to the dirty page, that this would > spike out delayed allocation, which would be unfortunate for *both* > ext4 and XFS. > > But maybe I'm misunderstanding what fsblock is doing, and there isn't > a problem here. Yeah, Dave's understanding of fsblock is correct. I might have stated things confusingly... fsblock allocates the in-memory fsblock metadata structure (~= struct buffer_head) at the time of block dirtying. It also asks the filesystem to respond to the dirtying event appropriately. In the case of say ext2, this means allocating a block on disk. Wheras XFS does the delalloc/reserve thing (yes, XFS appears to be working with fsblock well enough to get this far). fsblock really isn't too much different to buffer_head from an abstract capability / functionality point of view except that it is often more strict with things where I feel it makes sense. So for this particular example; in buffer.c, buffers do tend to be allocated when a page is dirtied, but not always, and even when they are, they can get reclaimed while the page is still dirty. fsblock tigtens this up.