tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Proposal: B_ARRIER (addresses wapbl performance?)

I'd like to propose a new buffer flag, B_ARRIER.  This flag would be
defined to cause a write barrier at whatever I/O request carries it.

In practice, this would mean using an ordered tag with SCSI disks
(because ordered tags do not complete until all prior simple-tagged
commands complete) and causing a cache flush for IDE disks (at least
until we get tagged queueing support for them).  I don't know how FUA
works for IDE disks but it's been suggested to me that FUA commands
cause all pending I/O to finish before they do -- that would suffice

The intent is to allow WAPBL to force all pending writes to complete
before a new journal write, without FUA or a full cache flush -- so
I/O *between* a pair of journal writes can go out to the disks without
waiting for a cache flush to complete.

Another proposal was to modify the SCSI code to use ordered tags for all
writes (some drivers already do this).  I think this could unduly impact
performance.  Using !B_ASYNC to cause a barrier is also not a good solution
as then the write becomes, well, synchronous.

Thor Lancelot Simon                               
    "Even experienced UNIX users occasionally enter rm *.* at the UNIX
     prompt only to realize too late that they have removed the wrong
     segment of the directory structure." - Microsoft WSS whitepaper

Home | Main Index | Thread Index | Old Index