Re: Poor read performance when sequential write presents

Jens Axboe (axboe@suse.de)
Mon, 27 May 2002 10:06:32 +0200


On Fri, May 24 2002, Andrew Morton wrote:
> > What kinds of phenomena appear to be associated with IDE's latencies?
> > I recall some comments from prior IDE maintainers on poor interactions
> > between generic disk I/O layers and IDE drivers, particularly with
> > respect to small transactions being given to the drivers to perform.
> > Are these comments still relevant, or is this of a different nature?
>
> I assume that there's a difference in the way in which the generic layer
> treats queueing for IDE devices. In 2.4, IDE devices are `head active',
> so the request at the head of the queue is under I/O. But SCSI isn't
> head-active. Requests get removed from the head of the queue prior to
> being serviced. At least, that's how I think it goes. I also believe that

That's correct for IDE when the queue is unplugged (if plugged, first
request is ok to touch).

> the 2.4 elevator does not look at the active request at the head when making
> merging decisions.

When unplugged, right.

> But in 2.5, head-activeness went away and as far as I know, IDE and SCSI are
> treated the same. Odd.

It didn't really go away, it just gets handled automatically now.
elv_next_request() marks the request as started, in which case the i/o
scheduler won't consider it for merging etc. SCSI removes the request
directly after it has been marked started, while IDE leaves it on the
queue until it completes. For IDE TCQ, the behaviour is the same as with
SCSI.

-- 
Jens Axboe

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/