fix test against max send tokens
This commit was SVN r6531.
Этот коммит содержится в:
родитель
f41e4149fa
Коммит
7fa40e84ae
@ -615,7 +615,9 @@ static void mca_btl_gm_send_callback( struct gm_port* port, void* context, gm_st
|
||||
OPAL_THREAD_LOCK(&btl->gm_lock);
|
||||
frag = (mca_btl_gm_frag_t*)opal_list_remove_first(&btl->gm_pending);
|
||||
OPAL_THREAD_UNLOCK(&btl->gm_lock);
|
||||
mca_btl_gm_send(&btl->super, frag->endpoint, &frag->base, frag->hdr->tag);
|
||||
if(NULL != frag) {
|
||||
mca_btl_gm_send(&btl->super, frag->endpoint, &frag->base, frag->hdr->tag);
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -51,18 +51,18 @@ extern "C" {
|
||||
struct mca_btl_gm_component_t {
|
||||
mca_btl_base_component_1_0_0_t super; /**< base BTL component */
|
||||
|
||||
size_t gm_num_btls; /**< number of hcas available to the GM component */
|
||||
size_t gm_max_btls; /**< maximum number of supported hcas */
|
||||
struct mca_btl_gm_module_t **gm_btls; /**< array of available BTL modules */
|
||||
size_t gm_max_ports; /**< maximum number of ports per board */
|
||||
size_t gm_max_boards; /**< maximum number of boards */
|
||||
size_t gm_num_high_priority; /**< number of receive descriptors at high priority */
|
||||
size_t gm_num_repost;
|
||||
size_t gm_num_mru;
|
||||
size_t gm_eager_frag_size;
|
||||
size_t gm_max_frag_size;
|
||||
char* gm_port_name;
|
||||
int gm_debug; /**< turn on debug output */
|
||||
size_t gm_num_btls; /**< number of hcas available to the GM component */
|
||||
size_t gm_max_btls; /**< maximum number of supported hcas */
|
||||
struct mca_btl_gm_module_t **gm_btls; /**< array of available BTL modules */
|
||||
size_t gm_max_ports; /**< maximum number of ports per board */
|
||||
size_t gm_max_boards; /**< maximum number of boards */
|
||||
size_t gm_num_mru;
|
||||
size_t gm_eager_frag_size;
|
||||
size_t gm_max_frag_size;
|
||||
char* gm_port_name;
|
||||
int32_t gm_num_repost;
|
||||
int32_t gm_num_high_priority; /**< number of receive descriptors at high priority */
|
||||
int gm_debug; /**< turn on debug output */
|
||||
|
||||
int gm_free_list_num; /**< initial size of free lists */
|
||||
int gm_free_list_max; /**< maximum size of free lists */
|
||||
@ -95,11 +95,11 @@ struct mca_btl_gm_module_t {
|
||||
ompi_free_list_t gm_frag_user;
|
||||
|
||||
/* number of send/recv tokens */
|
||||
unsigned int gm_num_send_tokens;
|
||||
unsigned int gm_max_send_tokens;
|
||||
unsigned int gm_num_recv_tokens;
|
||||
unsigned int gm_max_recv_tokens;
|
||||
unsigned int gm_num_repost;
|
||||
int32_t gm_num_send_tokens;
|
||||
int32_t gm_max_send_tokens;
|
||||
int32_t gm_num_recv_tokens;
|
||||
int32_t gm_max_recv_tokens;
|
||||
int32_t gm_num_repost;
|
||||
|
||||
/* lock for accessing module state */
|
||||
opal_list_t gm_pending; /**< list of pending send descriptors */
|
||||
|
@ -198,8 +198,8 @@ static int
|
||||
mca_btl_gm_module_init (mca_btl_gm_module_t * btl)
|
||||
{
|
||||
mca_mpool_base_resources_t resources;
|
||||
size_t num_high_priority;
|
||||
size_t i;
|
||||
int32_t num_high_priority;
|
||||
int32_t i;
|
||||
int rc;
|
||||
|
||||
/* initialize objects */
|
||||
|
@ -109,7 +109,7 @@ OBJ_CLASS_DECLARATION(mca_btl_gm_frag_user_t);
|
||||
|
||||
#define MCA_BTL_GM_FRAG_POST(btl,frag) \
|
||||
do { \
|
||||
if(opal_list_get_size(&btl->gm_repost) < btl->gm_num_repost) { \
|
||||
if(opal_list_get_size(&btl->gm_repost) < (size_t)btl->gm_num_repost) { \
|
||||
OPAL_THREAD_LOCK(&btl->gm_lock); \
|
||||
opal_list_append(&btl->gm_repost, (opal_list_item_t*)frag); \
|
||||
OPAL_THREAD_UNLOCK(&btl->gm_lock); \
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user