1
1

Update the tcp BTL to fulfill the requirements for #1713.

This commit was SVN r20151.
Этот коммит содержится в:
George Bosilca 2008-12-17 22:15:12 +00:00
родитель 341ee1389c
Коммит 7d404d238d
2 изменённых файлов: 8 добавлений и 10 удалений

Просмотреть файл

@ -175,19 +175,19 @@ mca_btl_base_descriptor_t* mca_btl_tcp_alloc(
size_t size,
uint32_t flags)
{
mca_btl_tcp_frag_t* frag;
mca_btl_tcp_frag_t* frag = NULL;
int rc;
if(size <= btl->btl_eager_limit) {
MCA_BTL_TCP_FRAG_ALLOC_EAGER(frag, rc);
frag->segments[0].seg_len = size;
} else if (size <= btl->btl_max_send_size) {
MCA_BTL_TCP_FRAG_ALLOC_MAX(frag, rc);
frag->segments[0].seg_len = size;
} else {
}
if( OPAL_UNLIKELY(NULL == frag) ) {
return NULL;
}
frag->segments[0].seg_len = size;
frag->segments[0].seg_addr.pval = frag+1;
frag->base.des_src = frag->segments;

Просмотреть файл

@ -2,7 +2,7 @@
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
* University Research and Technology
* Corporation. All rights reserved.
* Copyright (c) 2004-2006 The University of Tennessee and The University
* Copyright (c) 2004-2008 The University of Tennessee and The University
* of Tennessee Research Foundation. All rights
* reserved.
* Copyright (c) 2004-2005 High Performance Computing Center Stuttgart,
@ -82,24 +82,22 @@ OBJ_CLASS_DECLARATION(mca_btl_tcp_frag_user_t);
#define MCA_BTL_TCP_FRAG_ALLOC_EAGER(frag, rc) \
{ \
\
ompi_free_list_item_t *item; \
OMPI_FREE_LIST_WAIT(&mca_btl_tcp_component.tcp_frag_eager, item, rc); \
OMPI_FREE_LIST_GET(&mca_btl_tcp_component.tcp_frag_eager, item, rc); \
frag = (mca_btl_tcp_frag_t*) item; \
}
#define MCA_BTL_TCP_FRAG_ALLOC_MAX(frag, rc) \
{ \
\
ompi_free_list_item_t *item; \
OMPI_FREE_LIST_WAIT(&mca_btl_tcp_component.tcp_frag_max, item, rc); \
OMPI_FREE_LIST_GET(&mca_btl_tcp_component.tcp_frag_max, item, rc); \
frag = (mca_btl_tcp_frag_t*) item; \
}
#define MCA_BTL_TCP_FRAG_ALLOC_USER(frag, rc) \
{ \
ompi_free_list_item_t *item; \
OMPI_FREE_LIST_WAIT(&mca_btl_tcp_component.tcp_frag_user, item, rc); \
OMPI_FREE_LIST_GET(&mca_btl_tcp_component.tcp_frag_user, item, rc); \
frag = (mca_btl_tcp_frag_t*) item; \
}