[petsc-dev] MPI_UNSIGNED_LONG_LONG in mpiuni.h
Jed Brown
jedbrown at mcs.anl.gov
Thu Apr 25 12:09:12 CDT 2013
Chetan Jhurani <chetan.jhurani at gmail.com> writes:
> Hi,
>
> mpiuni.h does not define MPI_UNSIGNED_LONG_LONG, which leads
> to a problem in defining MPIU_SIZE_T here in petscsys.h.
>
> #if (PETSC_SIZEOF_SIZE_T) == (PETSC_SIZEOF_INT)
> #define MPIU_SIZE_T MPI_UNSIGNED
> #elif (PETSC_SIZEOF_SIZE_T) == (PETSC_SIZEOF_LONG)
> #define MPIU_SIZE_T MPI_UNSIGNED_LONG
> #elif (PETSC_SIZEOF_SIZE_T) == (PETSC_SIZEOF_LONG_LONG)
> #define MPIU_SIZE_T MPI_UNSIGNED_LONG_LONG
mpiuni/mpi.h also has this unguarded statement. Do all Windows
compilers now provide 'long long'?
#define MPI_LONG_LONG_INT sizeof(long long)
We could make mpiuni define MPIU_SIZE_T itself instead of jumping
through hoops to find the matching type.
Chetan, what's your perspective about using stdint.h?
More information about the petsc-dev
mailing list