diff options
author | jhendersonHDF <jhenderson@hdfgroup.org> | 2022-03-28 12:31:38 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-28 12:31:38 (GMT) |
commit | 95b2c3b96b389a44eadc85c74922f079363720e0 (patch) | |
tree | e5d6a54d33c74b324fa64d6ef95edfc5f8e677cc /src/H5private.h | |
parent | 15971fbd160ab061725f238379cc638ed37f05ef (diff) | |
download | hdf5-95b2c3b96b389a44eadc85c74922f079363720e0.zip hdf5-95b2c3b96b389a44eadc85c74922f079363720e0.tar.gz hdf5-95b2c3b96b389a44eadc85c74922f079363720e0.tar.bz2 |
Hdf5 1 12 parallel compression merge (#1529)
* Fix the function cast error in H5Dchunk.c and activate (#1170)
`-Werror=cast-function-type`. Again.
* Parallel Compression improvements (#1302)
* Fix for parallel compression examples on Windows (#1459)
* Parallel compression adjustments for HDF5 1.12
* Committing clang-format changes
Co-authored-by: David Young <dyoung@hdfgroup.org>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Diffstat (limited to 'src/H5private.h')
-rw-r--r-- | src/H5private.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/src/H5private.h b/src/H5private.h index b0b5477..de451f6 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -515,6 +515,25 @@ typedef long int32_t; #define HSSIZET_MAX ((hssize_t)LLONG_MAX) #define HSSIZET_MIN (~(HSSIZET_MAX)) +#ifdef H5_HAVE_PARALLEL + +/* Define a type for safely sending size_t values with MPI */ +#if SIZE_MAX == UCHAR_MAX +#define H5_SIZE_T_AS_MPI_TYPE MPI_UNSIGNED_CHAR +#elif SIZE_MAX == USHRT_MAX +#define H5_SIZE_T_AS_MPI_TYPE MPI_UNSIGNED_SHORT +#elif SIZE_MAX == UINT_MAX +#define H5_SIZE_T_AS_MPI_TYPE MPI_UNSIGNED +#elif SIZE_MAX == ULONG_MAX +#define H5_SIZE_T_AS_MPI_TYPE MPI_UNSIGNED_LONG +#elif SIZE_MAX == ULLONG_MAX +#define H5_SIZE_T_AS_MPI_TYPE MPI_UNSIGNED_LONG_LONG +#else +#error "no suitable MPI type for size_t" +#endif + +#endif /* H5_HAVE_PARALLEL */ + /* * Types and max sizes for POSIX I/O. * OS X (Darwin) is odd since the max I/O size does not match the types. @@ -587,6 +606,9 @@ typedef long int32_t; #define LOCK_UN 0x08 #endif /* H5_HAVE_FLOCK */ +/* Function pointer typedef for qsort */ +typedef int (*H5_sort_func_cb_t)(const void *, const void *); + /* Typedefs and functions for timing certain parts of the library. */ /* A set of elapsed/user/system times emitted as a time point by the @@ -2668,6 +2690,14 @@ H5_DLL herr_t H5_mpi_comm_cmp(MPI_Comm comm1, MPI_Comm comm2, int *result); H5_DLL herr_t H5_mpi_info_cmp(MPI_Info info1, MPI_Info info2, int *result); H5_DLL herr_t H5_mpio_create_large_type(hsize_t num_elements, MPI_Aint stride_bytes, MPI_Datatype old_type, MPI_Datatype *new_type); +H5_DLL herr_t H5_mpio_gatherv_alloc(void *send_buf, int send_count, MPI_Datatype send_type, + const int recv_counts[], const int displacements[], + MPI_Datatype recv_type, hbool_t allgather, int root, MPI_Comm comm, + int mpi_rank, int mpi_size, void **out_buf, size_t *out_buf_num_entries); +H5_DLL herr_t H5_mpio_gatherv_alloc_simple(void *send_buf, int send_count, MPI_Datatype send_type, + MPI_Datatype recv_type, hbool_t allgather, int root, MPI_Comm comm, + int mpi_rank, int mpi_size, void **out_buf, + size_t *out_buf_num_entries); #endif /* H5_HAVE_PARALLEL */ /* Functions for debugging */ |