#include "petsc.h" int PetscSynchronizedBinaryRead(MPI_Comm comm,int fd,void *p,int n,PetscDataType type)Collective on MPI_Comm
comm | - the MPI communicator | |
fd | - the file | |
n | - the number of items to read | |
type | - the type of items to read (PETSC_INT, PETSC_DOUBLE or PETSC_SCALAR) |
PetscSynchronizedBinaryRead() uses byte swapping to work on all machines. Integers are stored on the file as 32 long, regardless of whether they are stored in the machine as 32 or 64, this means the same binary file may be read on any machine.
Note that Cray C90 and similar machines cannot generate files with 32 bit integers; use the flag -binary_longints to read files from the C90 on non-C90 machines. Cray T3E/T3D are the same as other Unix machines, not the same as the C90.
Level:developer
Location:src/sys/src/fileio/sysio.c
Index of all Sys routines
Table of Contents for all manual pages
Index of all manual pages