On Fri, Jun 17, 2011 at 07:41:41AM -0400, Edward Ned Harvey wrote:
> > From: Daniel Carosone [mailto:d...@geek.com.au]
> > Sent: Thursday, June 16, 2011 11:05 PM
> > 
> > the [sata] channel is idle, blocked on command completion, while
> > the heads seek.
> 
> I'm interested in proving this point.  Because I believe it's false.
> 
> Just hand waving for the moment ... Presenting the alternative viewpoint
> that I think is correct...
> 
> All drives, regardless of whether or not their disk cache or buffer is
> enabled, support PIO and DMA.  This means no matter the state of the cache
> or buffer, the bus will deliver information to/from the memory of the disk
> as fast as possible, and the disk will optimize the visible workload to the
> best of its ability, and the disk will report back an interrupt when each
> operation is completed out-of-order.

Yes, up to the that last "out-of-order". Without NCQ, requests are
in-order and wait for completion with the channel idle. 

> It would be stupid for a disk to hog the bus in an idle state.

Yes, but remember that ATA was designed originally to be stupid
(simple).  The complexity has crept in over time.  Understanding the
history and development order is important here.

So, for older ATA disks, commands would transfer relatively quickly
over the channel, which would then remain idle until a completion
interrupt. Systems got faster.  Write cache was added to make writes
"complete" faster, read cache (with prefetch) was added in the hope
of satisfying read requests faster and freeing up the channel. Systems
got faster. NCQ was added (rather, TCQ was reinvented and crippled) to
try and get better concurrency. NCQ supports only a few outstanding
ops, in part because write-cache was by then established practice
(turning it off would adversely impact benchmarks, especially for
software that couldn't take advantage of concurrency).

So, today with NCQ, writes are again essentially in-order (to cache)
until the cache is full and request start blocking.  NCQ may offer
some benefit to concurrent reads, but again of litle value if the cache
is full.

Furthermore, the disk controllers may not be doing such a great job
when given concurrent requests anyway, as Richard mentions elsewhere.
Will reply to those points a little later.

--
Dan.

Attachment: pgpEakN7OalNL.pgp
Description: PGP signature

_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to