Intel® Fortran Libraries Reference

Intel® Fortran Libraries Reference Intel® Fortran Libraries Reference

h.eng.cam.ac.uk
from h.eng.cam.ac.uk More from this publisher
12.07.2015 Views

2 Intel Fortran Libraries Referencepath(Input) Character. The path for the new FIFO.ilen(Input) INTEGER(4). The length of path string.imode(Input) INTEGER(4). The mode mask; specifies the FIFO's permissions. Octal file-access mode.ierror(Output) INTEGER(4). The error status.If successful ierror is set to zero; otherwise, an error code.The PXFMKFIFO subroutine creates a FIFO special file with name path. A FIFO special file issimilar to a pipe, except that it is created in a different way. Once a FIFO special file is created,any process can open it for reading or writing in the same way as an ordinary file.However, the FIFO file has to be open at both ends simultaneously before you can proceed to doany input or output operations on it. Opening a FIFO for reading normally blocks it until someother process opens the same FIFO for writing, and vice versa.See Also: “PXFISFIFO”PXFOPENPOSIX Subroutine: Opens or creates a file.Module: USE IFPOSIXSyntaxCALL PXFOPEN (path, ilen, iopenflag, imode, ifildes, ierror)path(Input) Character. The path of the file to be opened or created.ilen(Input) INTEGER(4). The length of path string.iopenflag(Input) INTEGER(4). The flags for the file. (For possible constant names that can be passed toPXFCONST or IPXFCONST, see below.)imode(Input) INTEGER(4). The permissions for a new file. This argument should always be specifiedwhen iopenflag = O_CREAT; otherwise, it is ignored. (For possible permissions, see below.)2-314

Descriptions of the Library Routines 2ifildes(Output) INTEGER(4). The returned file descriptor for the opened or created file.ierror(Output) INTEGER(4). The error status.If successful, ierror is set to zero; otherwise, an error code.For iopenflag, you should specify one of the following constant values:• O_RDONLY (read only)• O_WRONLY (write only)• O_RDWR (read and write)In addition, you can also specify one of the following constant values by using a bitwise inclusiveOR (IOR):ValueO_CREATO_EXCLO_NOCTTYO_TRUNCO_APPENDO_NONBLOCK (orO_NDELAY) 1O_SYNCO_NOFOLLOW 1O_DIRECTORY 1O_LARGEFILE 1O_BINARY 2O_SHORT_LIVED 2O_TEMPORARY 2ActionCreates and opens a file if the file does not exist.When used with O_CREAT, it causes the open to fail if the file already exists. Inthis case, a symbolic link exists, regardless of where it points to.If path refers to a terminal device, it prevents it from becoming the process'scontrolling terminal even if the process does not have one.If the file already exists, it is a regular file, and imode allows writing (its value isO_RDWR or O_WRONLY), it causes the file to be truncated to length 0.Opens the file in append mode. Before each write, the file pointer is positionedat the end of the file, as if with PXFLSEEK.When possible, opens the file in non-blocking mode. Neither the open nor anysubsequent operations on the file descriptor that is returned will cause thecalling process to wait. This mode need not have any effect on files other thanFIFOs.Opens the file for synchronous I/O. Any writes on the resulting file descriptorwill block the calling process until the data has been physically written to theunderlying hardware.If path is a symbolic link, it causes the open to fail.If path is not a directory, it causes the open to fail.On 32-bit systems that support the Large Files System, it allows files whosesizes cannot be represented in 31 bits to be opened.Opens the file in binary (untranslated) mode.Creates the file as temporary. If possible, it does not flush to the disk.Creates the file as temporary. The file is deleted when last file handle is closed.2-315

Descriptions of the Library Routines 2ifildes(Output) INTEGER(4). The returned file descriptor for the opened or created file.ierror(Output) INTEGER(4). The error status.If successful, ierror is set to zero; otherwise, an error code.For iopenflag, you should specify one of the following constant values:• O_RDONLY (read only)• O_WRONLY (write only)• O_RDWR (read and write)In addition, you can also specify one of the following constant values by using a bitwise inclusiveOR (IOR):ValueO_CREATO_EXCLO_NOCTTYO_TRUNCO_APPENDO_NONBLOCK (orO_NDELAY) 1O_SYNCO_NOFOLLOW 1O_DIRECTORY 1O_LARGEFILE 1O_BINARY 2O_SHORT_LIVED 2O_TEMPORARY 2ActionCreates and opens a file if the file does not exist.When used with O_CREAT, it causes the open to fail if the file already exists. Inthis case, a symbolic link exists, regardless of where it points to.If path refers to a terminal device, it prevents it from becoming the process'scontrolling terminal even if the process does not have one.If the file already exists, it is a regular file, and imode allows writing (its value isO_RDWR or O_WRONLY), it causes the file to be truncated to length 0.Opens the file in append mode. Before each write, the file pointer is positionedat the end of the file, as if with PXFLSEEK.When possible, opens the file in non-blocking mode. Neither the open nor anysubsequent operations on the file descriptor that is returned will cause thecalling process to wait. This mode need not have any effect on files other thanFIFOs.Opens the file for synchronous I/O. Any writes on the resulting file descriptorwill block the calling process until the data has been physically written to theunderlying hardware.If path is a symbolic link, it causes the open to fail.If path is not a directory, it causes the open to fail.On 32-bit systems that support the Large Files System, it allows files whosesizes cannot be represented in 31 bits to be opened.Opens the file in binary (untranslated) mode.Creates the file as temporary. If possible, it does not flush to the disk.Creates the file as temporary. The file is deleted when last file handle is closed.2-315

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!