summaryrefslogtreecommitdiffstats
path: root/src/H5public.h
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@koziol.gov>2020-03-20 21:39:55 (GMT)
committerQuincey Koziol <koziol@koziol.gov>2020-03-23 23:05:37 (GMT)
commit5144eedd2e03716a3fa9a293ecafa8c26c43937b (patch)
tree1ce0d4741df16c15eefc02d816f3209234842462 /src/H5public.h
parent4065a506bc479ffc4c0cd46d2aa8ef47005e7f67 (diff)
downloadhdf5-5144eedd2e03716a3fa9a293ecafa8c26c43937b.zip
hdf5-5144eedd2e03716a3fa9a293ecafa8c26c43937b.tar.gz
hdf5-5144eedd2e03716a3fa9a293ecafa8c26c43937b.tar.bz2
Revise API for H5get_alloc_stats() to take a struct instead of separate values.
Diffstat (limited to 'src/H5public.h')
-rw-r--r--src/H5public.h17
1 files changed, 14 insertions, 3 deletions
diff --git a/src/H5public.h b/src/H5public.h
index f8a9d58..4ad975c 100644
--- a/src/H5public.h
+++ b/src/H5public.h
@@ -340,6 +340,19 @@ typedef struct H5O_token_t {
uint8_t __data[H5O_MAX_TOKEN_SIZE];
} H5O_token_t;
+/*
+ * Allocation statistics info struct
+ */
+typedef struct H5_alloc_stats_t {
+ unsigned long long total_alloc_bytes; /* Running count of total # of bytes allocated */
+ size_t curr_alloc_bytes; /* Current # of bytes allocated */
+ size_t peak_alloc_bytes; /* Peak # of bytes allocated */
+ size_t max_block_size; /* Largest block allocated */
+ size_t total_alloc_blocks_count; /* Running count of total # of blocks allocated */
+ size_t curr_alloc_blocks_count; /* Current # of blocks allocated */
+ size_t peak_alloc_blocks_count; /* Peak # of blocks allocated */
+} H5_alloc_stats_t;
+
/* Functions in H5.c */
H5_DLL herr_t H5open(void);
H5_DLL herr_t H5close(void);
@@ -350,9 +363,7 @@ H5_DLL herr_t H5set_free_list_limits (int reg_global_lim, int reg_list_lim,
int blk_list_lim);
H5_DLL herr_t H5get_free_list_sizes(size_t *reg_size, size_t *arr_size,
size_t *blk_size, size_t *fac_size);
-H5_DLL herr_t H5get_alloc_stats(unsigned long long *total_alloc_bytes, size_t *curr_alloc_bytes,
- size_t *peak_alloc_bytes, size_t *max_block_size, size_t *total_alloc_blocks_count,
- size_t *curr_alloc_blocks_count, size_t *peak_alloc_blocks_count);
+H5_DLL herr_t H5get_alloc_stats(H5_alloc_stats_t *stats);
H5_DLL herr_t H5get_libversion(unsigned *majnum, unsigned *minnum,
unsigned *relnum);
H5_DLL herr_t H5check_version(unsigned majnum, unsigned minnum,