Mercury
mercury_bulk.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2013 Argonne National Laboratory, Department of Energy,
3  *                    UChicago Argonne, LLC and The HDF Group.
4  * All rights reserved.
5  *
6  * The full copyright notice, including terms governing use, modification,
7  * and redistribution, is contained in the COPYING file that can be
8  * found at the root of the source code distribution tree.
9  */
10 
11 #ifndef MERCURY_BULK_H
12 #define MERCURY_BULK_H
13 
14 #include "mercury_types.h"
15 
16 #ifdef __cplusplus
17 extern "C" {
18 #endif
19 
28 HG_EXPORT hg_return_t
30 
36 HG_EXPORT hg_return_t
37 HG_Bulk_finalize(void);
38 
48 HG_EXPORT hg_return_t
49 HG_Bulk_initialized(hg_bool_t *flag, na_class_t **na_class);
50 
70 HG_EXPORT hg_return_t
71 HG_Bulk_handle_create(size_t count, void **buf_ptrs, const size_t *buf_sizes,
72  unsigned long flags, hg_bulk_t *handle);
73 
81 HG_EXPORT hg_return_t
83 
103 HG_EXPORT hg_return_t
104 HG_Bulk_handle_access(hg_bulk_t handle, size_t offset, size_t size,
105  unsigned long flags, unsigned int max_count, void **buf_ptrs,
106  size_t *buf_sizes, unsigned int *actual_count);
107 
115 HG_EXPORT size_t
117 
125 HG_EXPORT size_t
127 
135 HG_EXPORT size_t
137 
147 HG_EXPORT hg_return_t
148 HG_Bulk_handle_serialize(void *buf, size_t buf_size, hg_bulk_t handle);
149 
159 HG_EXPORT hg_return_t
160 HG_Bulk_handle_deserialize(hg_bulk_t *handle, const void *buf, size_t buf_size);
161 
178 HG_EXPORT hg_return_t
179 HG_Bulk_transfer(hg_bulk_op_t op, na_addr_t origin_addr, hg_bulk_t origin_handle,
180  size_t origin_offset, hg_bulk_t local_handle, size_t local_offset,
181  size_t size, hg_bulk_request_t *request);
182 
192 HG_EXPORT hg_return_t
193 HG_Bulk_wait(hg_bulk_request_t request, unsigned int timeout,
194  hg_status_t *status);
195 
196 #ifdef __cplusplus
197 }
198 #endif
199 
200 #endif /* MERCURY_BULK_H */
void * hg_bulk_request_t
Definition: mercury_types.h:24
HG_EXPORT hg_return_t HG_Bulk_init(na_class_t *na_class)
Initialize the Mercury bulk layer.
HG_EXPORT hg_return_t HG_Bulk_finalize(void)
Finalize the Mercury bulk layer.
HG_EXPORT hg_return_t HG_Bulk_handle_free(hg_bulk_t handle)
Free bulk handle.
void * hg_bulk_t
Definition: mercury_types.h:23
void * na_addr_t
Definition: na.h:20
HG_EXPORT size_t HG_Bulk_handle_get_size(hg_bulk_t handle)
Get total size of data abstracted by bulk handle.
HG_EXPORT hg_return_t HG_Bulk_handle_deserialize(hg_bulk_t *handle, const void *buf, size_t buf_size)
Deserialize bulk handle from a buffer.
HG_EXPORT hg_return_t HG_Bulk_transfer(hg_bulk_op_t op, na_addr_t origin_addr, hg_bulk_t origin_handle, size_t origin_offset, hg_bulk_t local_handle, size_t local_offset, size_t size, hg_bulk_request_t *request)
Transfer data to/from origin using abstract bulk handles.
HG_EXPORT size_t HG_Bulk_handle_get_serialize_size(hg_bulk_t handle)
Get size required to serialize bulk handle.
hg_bulk_op_t
Definition: mercury_types.h:26
HG_EXPORT hg_return_t HG_Bulk_initialized(hg_bool_t *flag, na_class_t **na_class)
Indicate whether HG_Bulk_init has been called and return associated network class.
HG_EXPORT size_t HG_Bulk_handle_get_segment_count(hg_bulk_t handle)
Get total number of segments abstracted by bulk handle.
HG_EXPORT hg_return_t HG_Bulk_handle_create(size_t count, void **buf_ptrs, const size_t *buf_sizes, unsigned long flags, hg_bulk_t *handle)
Create abstract bulk handle from specified memory segments.
HG_EXPORT hg_return_t HG_Bulk_wait(hg_bulk_request_t request, unsigned int timeout, hg_status_t *status)
Wait for a bulk operation request to complete.
HG_EXPORT hg_return_t HG_Bulk_handle_access(hg_bulk_t handle, size_t offset, size_t size, unsigned long flags, unsigned int max_count, void **buf_ptrs, size_t *buf_sizes, unsigned int *actual_count)
Access bulk handle to retrieve memory segments abstracted by handle.
enum hg_return hg_return_t
HG_EXPORT hg_return_t HG_Bulk_handle_serialize(void *buf, size_t buf_size, hg_bulk_t handle)
Serialize bulk handle into a buffer.
hg_bool_t hg_status_t
Definition: mercury_types.h:18