Make some function static. Optimize the fast path. Still working on the latency ...
This commit was SVN r10787.
Этот коммит содержится в:
родитель
21c542f0a5
Коммит
5617cb1a0a
@ -50,7 +50,24 @@ OBJ_CLASS_INSTANCE(
|
|||||||
NULL
|
NULL
|
||||||
);
|
);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Static functions.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Match incoming recv_frags against posted receives.
|
||||||
|
* Supports out of order delivery.
|
||||||
|
*
|
||||||
|
* @param frag_header (IN) Header of received recv_frag.
|
||||||
|
* @param frag_desc (IN) Received recv_frag descriptor.
|
||||||
|
* @param match_made (OUT) Flag indicating wether a match was made.
|
||||||
|
* @param additional_matches (OUT) List of additional matches
|
||||||
|
* @return OMPI_SUCCESS or error status on failure.
|
||||||
|
*/
|
||||||
|
static int mca_pml_ob1_recv_frag_match( mca_btl_base_module_t *btl,
|
||||||
|
mca_pml_ob1_match_hdr_t *hdr,
|
||||||
|
mca_btl_base_segment_t* segments,
|
||||||
|
size_t num_segments );
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Callback from BTL on receive.
|
* Callback from BTL on receive.
|
||||||
@ -429,11 +446,10 @@ static bool mca_pml_ob1_check_cantmatch_for_match(
|
|||||||
* - fragments may be corrupt
|
* - fragments may be corrupt
|
||||||
* - this routine may be called simultaneously by more than one thread
|
* - this routine may be called simultaneously by more than one thread
|
||||||
*/
|
*/
|
||||||
int mca_pml_ob1_recv_frag_match(
|
static int mca_pml_ob1_recv_frag_match( mca_btl_base_module_t *btl,
|
||||||
mca_btl_base_module_t *btl,
|
mca_pml_ob1_match_hdr_t *hdr,
|
||||||
mca_pml_ob1_match_hdr_t *hdr,
|
mca_btl_base_segment_t* segments,
|
||||||
mca_btl_base_segment_t* segments,
|
size_t num_segments )
|
||||||
size_t num_segments)
|
|
||||||
{
|
{
|
||||||
/* local variables */
|
/* local variables */
|
||||||
uint16_t next_msg_seq_expected, frag_msg_seq;
|
uint16_t next_msg_seq_expected, frag_msg_seq;
|
||||||
|
@ -113,23 +113,6 @@ OMPI_DECLSPEC void mca_pml_ob1_recv_frag_callback(
|
|||||||
void* cbdata
|
void* cbdata
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
|
||||||
* Match incoming recv_frags against posted receives.
|
|
||||||
* Supports out of order delivery.
|
|
||||||
*
|
|
||||||
* @param frag_header (IN) Header of received recv_frag.
|
|
||||||
* @param frag_desc (IN) Received recv_frag descriptor.
|
|
||||||
* @param match_made (OUT) Flag indicating wether a match was made.
|
|
||||||
* @param additional_matches (OUT) List of additional matches
|
|
||||||
* @return OMPI_SUCCESS or error status on failure.
|
|
||||||
*/
|
|
||||||
OMPI_DECLSPEC int mca_pml_ob1_recv_frag_match(
|
|
||||||
mca_btl_base_module_t* btl,
|
|
||||||
mca_pml_ob1_match_hdr_t *hdr,
|
|
||||||
mca_btl_base_segment_t* segments,
|
|
||||||
size_t num_segments);
|
|
||||||
|
|
||||||
|
|
||||||
#if defined(c_plusplus) || defined(__cplusplus)
|
#if defined(c_plusplus) || defined(__cplusplus)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -231,6 +231,7 @@ do {
|
|||||||
do { \
|
do { \
|
||||||
(request)->req_recv.req_base.req_ompi.req_status.MPI_TAG = (hdr)->hdr_tag; \
|
(request)->req_recv.req_base.req_ompi.req_status.MPI_TAG = (hdr)->hdr_tag; \
|
||||||
(request)->req_recv.req_base.req_ompi.req_status.MPI_SOURCE = (hdr)->hdr_src; \
|
(request)->req_recv.req_base.req_ompi.req_status.MPI_SOURCE = (hdr)->hdr_src; \
|
||||||
|
(request)->req_bytes_delivered = (request)->req_recv.req_bytes_packed; \
|
||||||
\
|
\
|
||||||
PERUSE_TRACE_COMM_EVENT( PERUSE_COMM_MSG_MATCH_POSTED_REQ, \
|
PERUSE_TRACE_COMM_EVENT( PERUSE_COMM_MSG_MATCH_POSTED_REQ, \
|
||||||
&((request)->req_recv.req_base), PERUSE_RECV ); \
|
&((request)->req_recv.req_base), PERUSE_RECV ); \
|
||||||
@ -249,8 +250,6 @@ do {
|
|||||||
&(request)->req_bytes_delivered ); \
|
&(request)->req_bytes_delivered ); \
|
||||||
PERUSE_TRACE_COMM_EVENT (PERUSE_COMM_REQ_XFER_BEGIN, \
|
PERUSE_TRACE_COMM_EVENT (PERUSE_COMM_REQ_XFER_BEGIN, \
|
||||||
&((request)->req_recv.req_base), PERUSE_RECV); \
|
&((request)->req_recv.req_base), PERUSE_RECV); \
|
||||||
} else { \
|
|
||||||
(request)->req_bytes_delivered = (request)->req_recv.req_bytes_packed; \
|
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
@ -268,6 +267,7 @@ do {
|
|||||||
bytes_received, \
|
bytes_received, \
|
||||||
bytes_delivered) \
|
bytes_delivered) \
|
||||||
do { \
|
do { \
|
||||||
|
bytes_delivered = 0; \
|
||||||
if(request->req_recv.req_bytes_packed > 0) { \
|
if(request->req_recv.req_bytes_packed > 0) { \
|
||||||
struct iovec iov[MCA_BTL_DES_MAX_SEGMENTS]; \
|
struct iovec iov[MCA_BTL_DES_MAX_SEGMENTS]; \
|
||||||
uint32_t iov_count = 0; \
|
uint32_t iov_count = 0; \
|
||||||
@ -296,8 +296,6 @@ do {
|
|||||||
&max_data, \
|
&max_data, \
|
||||||
&free_after); \
|
&free_after); \
|
||||||
bytes_delivered = max_data; \
|
bytes_delivered = max_data; \
|
||||||
} else { \
|
|
||||||
bytes_delivered = 0; \
|
|
||||||
} \
|
} \
|
||||||
} while (0)
|
} while (0)
|
||||||
|
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user