Guardian Application Conversion Guide
Improving I/O Performance Using Direct I/O Transfers
Converting Other Parts of an Application
8–36 096047 Tandem Computers Incorporated
When You Must Use
PFS Buffers
Your existing program might execute one or more of the following types of nowait
I/O operations. In each case, you must avoid using direct I/O transfers.
Multiple nowait READ[X] operations
If you execute a second nowait READ[X] before you call AWAITIO[X] to complete
the previous nowait READ[X] and you are using the same I/O buffer, use PFS
buffers; otherwise, your data might be overwritten.
Multiple nowait WRITE[X] operations
If you initiate more than one nowait WRITE[X] using the same I/O buffer and you
change the contents of the buffer between initiation and completion of a WRITE[X]
operation, you might write incorrect data. Whether you are using PFS buffers or
direct transfers, avoid changing the contents of your WRITE[X] buffer between
initiation and completion of the WRITE[X] operation.
Multiple nowait WRITEREAD[X] operations
If multiple WRITEREAD[X] operations share the same I/O buffer, use PFS buffers
and restore the buffer to the same value immediately after each WRITEREAD[X]
finishes.
For the above cases, if you open a file using the OPEN procedure, no conversion is
necessary. When you execute the OPEN procedure, the system uses PFS buffers by
default for nowait I/O operations.
However, if you open a file using the FILE_OPEN_ procedure, issue a SETMODE 72
function with
parameter-1
set to 1 to force the use of PFS buffers. Refer to “Using
the SETMODE 72 Function” in the previous subsection for more information.