hpx/collectives/channel_communicator.hpp
hpx/collectives/channel_communicator.hpp#
See Public API for a list of names and headers that are part of the public HPX API.
-
namespace hpx
-
namespace collectives
Functions
-
hpx::future<channel_communicator> create_channel_communicator(char const *basename, num_sites_arg num_sites = num_sites_arg(), this_site_arg this_site = this_site_arg())#
Create a new communicator object usable with peer-to-peer channel-based operations
This functions creates a new communicator object that can be called in order to pre-allocate a communicator object usable with multiple invocations of channel-based peer-to-peer operations.
- Parameters
basename – The base name identifying the collective operation
num_sites – The number of participating sites (default: all localities).
this_site – The sequence number of this invocation (usually the locality id). This value is optional and defaults to whatever hpx::get_locality_id() returns.
- Returns
This function returns a future to a new communicator object usable with the collective operation.
-
channel_communicator create_channel_communicator(hpx::launch::sync_policy, char const *basename, num_sites_arg num_sites = num_sites_arg(), this_site_arg this_site = this_site_arg())#
Create a new communicator object usable with peer-to-peer channel-based operations
This functions creates a new communicator object that can be called in order to pre-allocate a communicator object usable with multiple invocations of channel-based peer-to-peer operations.
- Parameters
basename – The base name identifying the collective operation
num_sites – The number of participating sites (default: all localities).
this_site – The sequence number of this invocation (usually the locality id). This value is optional and defaults to whatever hpx::get_locality_id() returns.
- Returns
This function returns a new communicator object usable with the collective operation.
-
template<typename T>
hpx::future<void> set(channel_communicator comm, that_site_arg site, T &&value, tag_arg tag = tag_arg())# Send a value to the given site
This function sends a value to the given site based on the given communicator.
- Parameters
comm – The channel communicator object to use for the data transfer
site – The destination site
value – The value to send
tag – The (optional) tag identifying the concrete operation
- Returns
This function returns a future<void> that becomes ready once the data transfer operation has finished.
-
template<typename T>
hpx::future<T> get(channel_communicator comm, that_site_arg site, tag_arg tag = tag_arg())# Send a value to the given site
This function receives a value from the given site based on the given communicator.
- Parameters
comm – The channel communicator object to use for the data transfer
site – The source site
- Returns
This function returns a future<T> that becomes ready once the data transfer operation has finished. The future will hold the received value.
-
hpx::future<channel_communicator> create_channel_communicator(char const *basename, num_sites_arg num_sites = num_sites_arg(), this_site_arg this_site = this_site_arg())#
-
namespace collectives