Lines Matching refs:num
281 PetscErrorCode PetscBinaryRead(int fd, void *data, PetscCount num, PetscInt *count, PetscDataType t… in PetscBinaryRead() argument
283 size_t typesize, m = (size_t)num, n = 0, maxblock = 65536; in PetscBinaryRead()
294 …PetscCheck(num >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Trying to read a negative amount … in PetscBinaryRead()
295 if (!num) PetscFunctionReturn(PETSC_SUCCESS); in PetscBinaryRead()
305 if (type == PETSC_BIT_LOGICAL) m = PetscBTLength(num); in PetscBinaryRead()
313 PetscInt cnt = num * ((type == PETSC_REAL) ? 1 : 2); in PetscBinaryRead()
334 num = n / typesize; /* Should we require `n % typesize == 0` ? */ in PetscBinaryRead()
335 …if (count) PetscCall(PetscIntCast(num, count)); /* TODO: This is most likely wrong for PETSC_BIT_L… in PetscBinaryRead()
339 PetscInt i, cnt = num * ((type == PETSC_REAL) ? 1 : 2); in PetscBinaryRead()
348 if (!PetscBinaryBigEndian()) PetscCall(PetscByteSwap(ptmp, type, num)); in PetscBinaryRead()
616 PetscErrorCode PetscBinarySynchronizedRead(MPI_Comm comm, int fd, void *data, PetscInt num, PetscIn… in PetscBinarySynchronizedRead() argument
626 num = 64; in PetscBinarySynchronizedRead()
628 fname = (char *)malloc(num * sizeof(char)); in PetscBinarySynchronizedRead()
636 if (rank == 0) ibuf[0] = (PetscInt)PetscBinaryRead(fd, data, num, count ? &ibuf[1] : NULL, type); in PetscBinarySynchronizedRead()
644 PetscCall(PetscMPIIntCast(count ? ibuf[1] : num, &cnt)); in PetscBinarySynchronizedRead()