OpenMPI
0.1.1
|
#include "ompi_config.h"
#include "opal/class/opal_list.h"
#include "opal/util/crc.h"
#include "opal/threads/mutex.h"
#include "opal/prefetch.h"
#include "opal/util/output.h"
#include "orte/util/name_fns.h"
#include "orte/runtime/orte_globals.h"
#include "orte/mca/notifier/notifier.h"
#include "orte/mca/errmgr/errmgr.h"
#include "ompi/constants.h"
#include "ompi/communicator/communicator.h"
#include "ompi/mca/pml/pml.h"
#include "ompi/mca/pml/base/base.h"
#include "ompi/peruse/peruse-internal.h"
#include "ompi/memchecker.h"
#include "pml_csum.h"
#include "pml_csum_comm.h"
#include "pml_csum_recvfrag.h"
#include "pml_csum_recvreq.h"
#include "pml_csum_sendreq.h"
#include "pml_csum_hdr.h"
Macros | |
#define | PML_MAX_SEQ ~((mca_pml_sequence_t)0); |
Functions | |
OBJ_CLASS_INSTANCE (mca_pml_csum_buffer_t, ompi_free_list_item_t, NULL, NULL) | |
OBJ_CLASS_INSTANCE (mca_pml_csum_recv_frag_t, opal_list_item_t, NULL, NULL) | |
static void | dump_csum_error_data (mca_btl_base_segment_t *segments, size_t num_segments) |
Static functions. More... | |
static void | append_frag_to_list (opal_list_t *queue, mca_btl_base_module_t *btl, mca_pml_csum_match_hdr_t *hdr, mca_btl_base_segment_t *segments, size_t num_segments, mca_pml_csum_recv_frag_t *frag) |
Append a unexpected descriptor to a queue. More... | |
static int | mca_pml_csum_recv_frag_match (mca_btl_base_module_t *btl, mca_pml_csum_match_hdr_t *hdr, mca_btl_base_segment_t *segments, size_t num_segments, int type) |
Match incoming recv_frags against posted receives. More... | |
static mca_pml_csum_recv_request_t * | match_one (mca_btl_base_module_t *btl, mca_pml_csum_match_hdr_t *hdr, mca_btl_base_segment_t *segments, size_t num_segments, ompi_communicator_t *comm_ptr, mca_pml_csum_comm_proc_t *proc, mca_pml_csum_recv_frag_t *frag) |
void | mca_pml_csum_recv_frag_callback_match (mca_btl_base_module_t *btl, mca_btl_base_tag_t tag, mca_btl_base_descriptor_t *des, void *cbdata) |
Callback from BTL on receipt of a recv_frag (match). | |
void | mca_pml_csum_recv_frag_callback_rndv (mca_btl_base_module_t *btl, mca_btl_base_tag_t tag, mca_btl_base_descriptor_t *des, void *cbdata) |
Callback from BTL on receipt of a recv_frag (rndv). | |
void | mca_pml_csum_recv_frag_callback_rget (mca_btl_base_module_t *btl, mca_btl_base_tag_t tag, mca_btl_base_descriptor_t *des, void *cbdata) |
Callback from BTL on receipt of a recv_frag (rget). | |
void | mca_pml_csum_recv_frag_callback_ack (mca_btl_base_module_t *btl, mca_btl_base_tag_t tag, mca_btl_base_descriptor_t *des, void *cbdata) |
Callback from BTL on receipt of a recv_frag (ack). | |
void | mca_pml_csum_recv_frag_callback_frag (mca_btl_base_module_t *btl, mca_btl_base_tag_t tag, mca_btl_base_descriptor_t *des, void *cbdata) |
Callback from BTL on receipt of a recv_frag (frag). | |
void | mca_pml_csum_recv_frag_callback_put (mca_btl_base_module_t *btl, mca_btl_base_tag_t tag, mca_btl_base_descriptor_t *des, void *cbdata) |
Callback from BTL on receipt of a recv_frag (put). | |
void | mca_pml_csum_recv_frag_callback_fin (mca_btl_base_module_t *btl, mca_btl_base_tag_t tag, mca_btl_base_descriptor_t *des, void *cbdata) |
Callback from BTL on receipt of a recv_frag (fin). | |
static mca_pml_csum_recv_request_t * | get_posted_recv (opal_list_t *queue) |
static mca_pml_csum_recv_request_t * | get_next_posted_recv (opal_list_t *queue, mca_pml_csum_recv_request_t *req) |
static mca_pml_csum_recv_request_t * | match_incomming (mca_pml_csum_match_hdr_t *hdr, mca_pml_csum_comm_t *comm, mca_pml_csum_comm_proc_t *proc) |
static mca_pml_csum_recv_frag_t * | check_cantmatch_for_match (mca_pml_csum_comm_proc_t *proc) |
|
static |
Append a unexpected descriptor to a queue.
This function will allocate and initialize the fragment (if necessary) and then will add it to the specified queue. The allocated fragment is not returned to the caller.
References opal_list_append.
Referenced by mca_pml_csum_recv_frag_callback_match(), and mca_pml_csum_recv_frag_match().
|
static |
Static functions.
Dump data elements that caused a checksum violation
References mca_btl_base_segment_t::seg_len.
Referenced by mca_pml_csum_recv_frag_callback_ack(), mca_pml_csum_recv_frag_callback_fin(), mca_pml_csum_recv_frag_callback_frag(), mca_pml_csum_recv_frag_callback_match(), mca_pml_csum_recv_frag_callback_put(), mca_pml_csum_recv_frag_callback_rndv(), and mca_pml_csum_recv_request_progress_rndv().
|
static |
Match incoming recv_frags against posted receives.
RCS/CTS receive side matching.
Supports out of order delivery.
frag_header | (IN) Header of received recv_frag. |
frag_desc | (IN) Received recv_frag descriptor. |
match_made | (OUT) Flag indicating wether a match was made. |
additional_matches | (OUT) List of additional matches |
hdr | list of parameters needed for matching This list is also embeded in frag, but this allows to save a memory copy when a match is made in this routine. (IN) |
frag | pointer to receive fragment which we want to match (IN/OUT). If a match is not made, hdr is copied to frag. |
match_made | parameter indicating if we matched frag/ hdr (OUT) |
additional_matches | if a match is made with frag, we may be able to match fragments that previously have arrived out-of-order. If this is the case, the associated fragment descriptors are put on this list for further processing. (OUT) |
This routine is used to try and match a newly arrived message fragment to pre-posted receives. The following assumptions are made
We generate the MSG_ARRIVED event as soon as the PML is aware of a matching fragment arrival. Independing if it is received on the correct order or not. This will allow the tools to figure out if the messages are not received in the correct order (if multiple network interfaces).
We generate the SEARCH_POSTED_QUEUE only when the message is received in the correct sequence. Otherwise, we delay the event generation until we reach the correct sequence number.
The match is over. We generate the SEARCH_POSTED_Q_END here, before going into the mca_pml_csum_check_cantmatch_for_match so we can make a difference for the searching time for all messages.
References append_frag_to_list(), mca_pml_csum_comm_proc_t::expected_sequence, mca_pml_csum_comm_proc_t::frags_cant_match, mca_pml_csum_match_hdr_t::hdr_common, mca_pml_csum_match_hdr_t::hdr_ctx, mca_pml_csum_match_hdr_t::hdr_seq, mca_pml_csum_match_hdr_t::hdr_src, mca_pml_csum_match_hdr_t::hdr_tag, mca_pml_csum_common_hdr_t::hdr_type, mca_pml_comm_t::matching_lock, mca_pml_csum_recv_request_progress_rndv(), opal_list_get_size(), OPAL_THREAD_LOCK, and OPAL_THREAD_UNLOCK.
Referenced by mca_pml_csum_recv_frag_callback_match(), mca_pml_csum_recv_frag_callback_rget(), and mca_pml_csum_recv_frag_callback_rndv().