From mboxrd@z Thu Jan 1 00:00:00 1970 From: Werner Almesberger Subject: Re: barriers vs. reads Date: Tue, 22 Jun 2004 20:10:27 -0300 Sender: linux-fsdevel-owner@vger.kernel.org Message-ID: <20040622201027.J1325@almesberger.net> References: <20040622005302.A1325@almesberger.net> <20040622073919.GV12881@suse.de> <20040622045004.C1325@almesberger.net> <20040622075531.GX12881@suse.de> <20040622112802.GA21456@mail.shareable.org> <20040622113245.GA1104@suse.de> <20040622155308.G1325@almesberger.net> <20040622205748.GD3200@suse.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Jamie Lokier , linux-fsdevel@vger.kernel.org Return-path: Received: from almesberger.net ([63.105.73.238]:27149 "EHLO host.almesberger.net") by vger.kernel.org with ESMTP id S266570AbUFVXKq (ORCPT ); Tue, 22 Jun 2004 19:10:46 -0400 To: Jens Axboe Content-Disposition: inline In-Reply-To: <20040622205748.GD3200@suse.de>; from axboe@suse.de on Tue, Jun 22, 2004 at 10:57:49PM +0200 List-Id: linux-fsdevel.vger.kernel.org Jens Axboe wrote: > Overlapping requests are only detected if they start at the same > sector. > > The mechanism is just there because of the data structure use, [...] So even the special handling of requests that start with the same sector isn't required, and shouldn't be depended on, right ? > Bad idea, unless you have zero setup overhead for the hardware issued > commands. Linux will also attempt to remerge these requests when it > later discovers they are adjacent. You can block this by disallowing > merging of request with different priorities, but I really don't see why > you'd want to do that. It would be a net loss in the end anyways. The issue is that you may get large requests, in the middle of which a single page gets a higher priority, e.g. because the large request comes from a low-priority copy operation, and there's a high-priority reader concurrently working on the same file. In this case, the high-priority reader either has to wait for the whole low-priority request to crawl to the head of the queue (probably missing the deadline of the high-priority read), or we could take the request and raise its priority, giving our low-priority reader a nice boost. The latter isn't so bad if it happens every once in a while, but someone may figure out how to do this repeatedly, throwing off our bandwidth calculations. - Werner -- _________________________________________________________________________ / Werner Almesberger, Buenos Aires, Argentina wa@almesberger.net / /_http://www.almesberger.net/____________________________________________/