NewMadeleine

Documentation

nm_mcast_interface.h
Go to the documentation of this file.
1/* * NewMadeleine
2 * Copyright (C) 2021 (see AUTHORS file)
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or (at
7 * your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful, but
10 * WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * General Public License for more details.
13 */
14
15#ifndef NM_MCAST_H
16#define NM_MCAST_H
17
18#include <nm_coll_interface.h>
19
20
56typedef struct nm_mcast_service_s*nm_mcast_service_t;
57
59typedef void (*nm_mcast_send_notifier_t)(void*p_ref);
60
63{
69};
70
73
78
81
100void nm_mcast_send(nm_mcast_service_t nm_mcast, nm_comm_t p_recv_comm, int*p_dests, int*p_prios, int n_dests,
101 nm_tag_t tag, struct nm_data_s*p_data, nm_len_t hlen, nm_coll_tree_kind_t tree_kind);
102
108
111
116void nm_mcast_isend(nm_mcast_t*p_mcast, nm_comm_t p_comm, int*p_dests, int*p_prios,
117 int n_dests, nm_tag_t tag, struct nm_data_s*p_data, nm_len_t hlen, nm_coll_tree_kind_t tree_kind);
118
121
124
129
133#endif /* NM_MCAST_H */
134
enum nm_coll_tree_kind_e nm_coll_tree_kind_t
Definition: nm_coll_trees.h:54
nm_status_t nm_cond_status_t
status with synchronization (wait/signal)
void nm_mcast_set_default_tree_kind(nm_mcast_service_t nm_mcast, const nm_coll_tree_kind_t kind)
Change the default tree used for routing data.
void nm_mcast_send(nm_mcast_service_t nm_mcast, nm_comm_t p_recv_comm, int *p_dests, int *p_prios, int n_dests, nm_tag_t tag, struct nm_data_s *p_data, nm_len_t hlen, nm_coll_tree_kind_t tree_kind)
Send data in a blocking mode.
void nm_mcast_finalize(nm_mcast_service_t nm_mcast)
Release the mcast interface.
void(* nm_mcast_send_notifier_t)(void *p_ref)
Public abstraction for the callback called when the mcast_send is completed.
void nm_mcast_send_init(nm_mcast_service_t nm_mcast, nm_mcast_t *p_mcast)
Initialize a multicast send.
nm_mcast_service_t nm_mcast_init(nm_comm_t p_comm)
Initializes the mcast interface.
struct nm_mcast_service_s * nm_mcast_service_t
Public abstraction for a mcast service.
void nm_mcast_send_destroy(nm_mcast_t *p_mcast)
Free data allocated by nm_mcast_send_init()
void nm_mcast_isend(nm_mcast_t *p_mcast, nm_comm_t p_comm, int *p_dests, int *p_prios, int n_dests, nm_tag_t tag, struct nm_data_s *p_data, nm_len_t hlen, nm_coll_tree_kind_t tree_kind)
Send data in a non-blocking mode.
void nm_mcast_wait(nm_mcast_t *p_mcast)
Wait for a non-blocking multicast send.
void nm_mcast_send_set_notifier(nm_mcast_t *p_mcast, nm_mcast_send_notifier_t notifier, void *p_ref)
Attach a notifier to mcast_send, to be called when the root node of the multicast ends its sends.
nm_tag_t tag
the user-supplied tag
uint16_t hlen
length in header (header + data in header)
Definition: nm_headers.h:5
nm_mpi_communicator_t * p_comm
communicator used for communication
uint64_t nm_tag_t
user tags, 64 bits, contained in indirect hashtable
Definition: nm_types.h:58
uint64_t nm_len_t
data length used by nmad
Definition: nm_types.h:70
a data descriptor, used to pack/unpack data from app layout to/from contiguous buffers
Definition: nm_data.h:189
A multicast send request.
nm_mcast_send_notifier_t p_notifier
notification function to call uppon mcast completion
nm_cond_status_t cond_mcast_ended
nm_mcast_service_t p_mcast_service
void * p_notifier_ref
user-supplied parameter for the notifier