int mca_btl_udapl_send( struct mca_btl_base_module_t* btl, struct mca_btl_base_endpoint_t* endpoint, struct mca_btl_base_descriptor_t* des, mca_btl_base_tag_t tag) { mca_btl_udapl_frag_t* frag = (mca_btl_udapl_frag_t*)des; frag->endpoint = endpoint; frag->ftr = (mca_btl_udapl_footer_t *) ((char *)frag->segment.base.seg_addr.pval + frag->segment.base.seg_len); frag->ftr->tag = tag; frag->type = MCA_BTL_UDAPL_SEND; /* TODO - will inlining this give worthwhile performance? */ return mca_btl_udapl_endpoint_send(endpoint, frag); }
static inline int mca_btl_udapl_frag_progress_one( mca_btl_udapl_module_t* udapl_btl, mca_btl_udapl_frag_t* frag) { int rc; switch(frag->type) { case MCA_BTL_UDAPL_SEND: rc = mca_btl_udapl_endpoint_send(frag->endpoint, frag); break; case MCA_BTL_UDAPL_PUT: rc = mca_btl_udapl_put(&udapl_btl->super, frag->endpoint, &frag->base); break; default: rc = OMPI_ERROR; BTL_ERROR(("Error : Progressing pending operation, invalid type %d\n", frag->type)); break; } return rc; }