[Info-vax] yet another sys$qiow question
Stephen Hoffman
seaohveh at hoffmanlabs.invalid
Fri Aug 21 11:00:43 EDT 2015
On 2015-08-21 14:18:09 +0000, Craig A. Berry said:
> On 8/21/15 8:41 AM, Johnny Billquist wrote:
>
>> What is wrong with checking the IOSB before the I/O completes? There is
>> absolutely nothing wrong with that. And if it is non-zero, it means the
>> I/O already have completed, so there is no point in waiting, since it
>> will return immediately.
>
> Until the I/O completes, the status of the IOSB is undefined. Show me
> where there is a guarantee that if one longword of the IOSB has been
> written, that the other longword has also been written, i.e., that the
> entire IOSB is written atomically or in a single instruction. Without
> that guarantee, non-zero does not mean complete.
Aside from the discussion of volatile and variable modifications
out-of-compiler-scope being discussed else-thread, polling the IOSB is
a documented and supported approach.
Quoth The Fine Manual: "The process polls the I/O status block. If the
low-order word still contains zero, the I/O operation has not yet
completed. In this example, the program loops until the request is
complete."
<http://h30266.www3.hp.com/odl/vax/opsys/vmsos73/vmsos73/5841/5841pro_062.html>
--
Pure Personal Opinion | HoffmanLabs LLC
More information about the Info-vax
mailing list