BioCMAMC-ST
WrapMPI::HostIterationPayload Class Reference

Represents the payload of data on the host side for an iteration. More...

#include <iteration_payload.hpp>

Public Member Functions

void fill (const CmaUtils::IterationStatePtrType &current_reactor_state)
bool sendAll (std::size_t n_rank) noexcept
void wait () noexcept
bool send (size_t rank) noexcept
 Sends this payload to a specified MPI rank.

Public Attributes

std::span< const double > liquid_volumes
std::span< const std::size_t > liquid_neighbors_flat
std::span< const double > proba_leaving_flat
std::span< const double > liquid_out_flows
bool to_wait
std::array< MPI_Request, n_vector_sendrequests

Static Public Attributes

static constexpr std::size_t n_vector_send = 4

Detailed Description

Represents the payload of data on the host side for an iteration.

This class encapsulates the data to be sent

Member Function Documentation

◆ fill()

void WrapMPI::HostIterationPayload::fill ( const CmaUtils::IterationStatePtrType & current_reactor_state)

◆ send()

bool WrapMPI::HostIterationPayload::send ( size_t rank)
nodiscardnoexcept

Sends this payload to a specified MPI rank.

This function sends the liquid flows, liquid volumes, and gas volumes to a specified destination rank using MPI.

Parameters
rankThe MPI rank of the destination process.
Note
This method uses MPI to perform the send operation and assumes the MPI environment is initialized.
Here is the call graph for this function:

◆ sendAll()

bool WrapMPI::HostIterationPayload::sendAll ( std::size_t n_rank)
nodiscardnoexcept
Here is the call graph for this function:

◆ wait()

void WrapMPI::HostIterationPayload::wait ( )
noexcept

Member Data Documentation

◆ liquid_neighbors_flat

std::span<const std::size_t> WrapMPI::HostIterationPayload::liquid_neighbors_flat

◆ liquid_out_flows

std::span<const double> WrapMPI::HostIterationPayload::liquid_out_flows

◆ liquid_volumes

std::span<const double> WrapMPI::HostIterationPayload::liquid_volumes

◆ n_vector_send

std::size_t WrapMPI::HostIterationPayload::n_vector_send = 4
staticconstexpr

◆ proba_leaving_flat

std::span<const double> WrapMPI::HostIterationPayload::proba_leaving_flat

◆ requests

std::array<MPI_Request, n_vector_send> WrapMPI::HostIterationPayload::requests

◆ to_wait

bool WrapMPI::HostIterationPayload::to_wait

The documentation for this class was generated from the following files: