From 218a43850992bdd2050867f58db99e5f1c85860b Mon Sep 17 00:00:00 2001 From: Galen Shipman Date: Mon, 12 Jun 2006 22:09:03 +0000 Subject: [PATCH] finished the ompi_free_list_t class nightmare.. This commit was SVN r10314. --- ompi/class/ompi_free_list.h | 4 ++-- ompi/class/ompi_rb_tree.c | 4 ++-- ompi/mca/btl/gm/btl_gm_frag.h | 8 ++++---- ompi/mca/btl/mvapi/btl_mvapi.h | 2 +- ompi/mca/btl/mvapi/btl_mvapi_component.c | 4 ++-- ompi/mca/btl/mvapi/btl_mvapi_endpoint.h | 2 +- ompi/mca/btl/mvapi/btl_mvapi_frag.h | 8 ++++---- ompi/mca/btl/mx/btl_mx_frag.h | 6 +++--- ompi/mca/btl/openib/btl_openib.h | 2 +- ompi/mca/btl/openib/btl_openib_component.c | 4 ++-- ompi/mca/btl/openib/btl_openib_endpoint.h | 2 +- ompi/mca/btl/openib/btl_openib_frag.h | 8 ++++---- ompi/mca/btl/self/btl_self_frag.h | 13 +++++++------ ompi/mca/btl/sm/btl_sm_frag.h | 6 +++--- ompi/mca/btl/tcp/btl_tcp_frag.h | 8 ++++---- ompi/mca/btl/template/btl_template_frag.h | 12 ++++++------ ompi/mca/io/base/io_base_request.c | 5 +++-- ompi/mca/pml/dr/pml_dr_recvfrag.h | 8 ++++---- ompi/mca/pml/dr/pml_dr_recvreq.h | 10 ++++++---- ompi/mca/pml/dr/pml_dr_sendreq.h | 4 ++-- ompi/mca/pml/dr/pml_dr_vfrag.h | 5 +++-- ompi/mca/pml/ob1/pml_ob1_rdmafrag.h | 4 ++-- ompi/mca/pml/ob1/pml_ob1_recvfrag.h | 8 ++++---- ompi/mca/pml/ob1/pml_ob1_recvreq.h | 2 +- ompi/mca/pml/ob1/pml_ob1_sendreq.h | 4 ++-- ompi/mca/rcache/rb/rcache_rb_tree.c | 3 ++- 26 files changed, 76 insertions(+), 70 deletions(-) diff --git a/ompi/class/ompi_free_list.h b/ompi/class/ompi_free_list.h index 9eaae76c46..662fbb0db2 100644 --- a/ompi/class/ompi_free_list.h +++ b/ompi/class/ompi_free_list.h @@ -143,7 +143,7 @@ OMPI_DECLSPEC int ompi_free_list_parse( ompi_free_list_t* list, */ #define OMPI_FREE_LIST_WAIT(fl, item, rc) \ - rc = __ompi_free_list_wait( (fl), (ompi_free_list_item_t**)&(item) ) + rc = __ompi_free_list_wait( (fl), &(item) ) static inline int __ompi_free_list_wait( ompi_free_list_t* fl, ompi_free_list_item_t** item ) @@ -187,7 +187,7 @@ static inline int __ompi_free_list_wait( ompi_free_list_t* fl, opal_list_item_t* original; \ \ original = opal_atomic_lifo_push( &(fl)->super, \ - (opal_list_item_t*)item ); \ + &(item)->super); \ if( &(fl)->super.opal_lifo_ghost == original ) { \ OPAL_THREAD_LOCK(&(fl)->fl_lock); \ if((fl)->fl_num_waiting > 0) { \ diff --git a/ompi/class/ompi_rb_tree.c b/ompi/class/ompi_rb_tree.c index ab78621d7e..876b864d2e 100644 --- a/ompi/class/ompi_rb_tree.c +++ b/ompi/class/ompi_rb_tree.c @@ -218,7 +218,7 @@ int ompi_rb_tree_delete(ompi_rb_tree_t *tree, void *key) ompi_rb_tree_node_t * p; ompi_rb_tree_node_t * todelete; ompi_rb_tree_node_t * y; - opal_list_item_t * item; + ompi_free_list_item_t * item; p = ompi_rb_tree_find_node(tree, key); if (NULL == p) { @@ -256,7 +256,7 @@ int ompi_rb_tree_delete(ompi_rb_tree_t *tree, void *key) if (todelete->color == BLACK) { btree_delete_fixup(tree, y); } - item = (opal_list_item_t *) todelete; + item = (ompi_free_list_item_t *) todelete; OMPI_FREE_LIST_RETURN(&(tree->free_list), item); --tree->tree_size; return(OMPI_SUCCESS); diff --git a/ompi/mca/btl/gm/btl_gm_frag.h b/ompi/mca/btl/gm/btl_gm_frag.h index 4f17afab45..146614fb8a 100644 --- a/ompi/mca/btl/gm/btl_gm_frag.h +++ b/ompi/mca/btl/gm/btl_gm_frag.h @@ -77,7 +77,7 @@ OBJ_CLASS_DECLARATION(mca_btl_gm_frag_user_t); #define MCA_BTL_GM_FRAG_ALLOC_EAGER(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_gm_module_t*)btl)->gm_frag_eager, item, rc); \ frag = (mca_btl_gm_frag_t*) item; \ frag->my_list = &((mca_btl_gm_module_t*)btl)->gm_frag_eager; \ @@ -86,7 +86,7 @@ OBJ_CLASS_DECLARATION(mca_btl_gm_frag_user_t); #define MCA_BTL_GM_FRAG_ALLOC_MAX(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_gm_module_t*)btl)->gm_frag_max, item, rc); \ frag = (mca_btl_gm_frag_t*) item; \ frag->my_list = &((mca_btl_gm_module_t*)btl)->gm_frag_max; \ @@ -94,7 +94,7 @@ OBJ_CLASS_DECLARATION(mca_btl_gm_frag_user_t); #define MCA_BTL_GM_FRAG_ALLOC_USER(btl, frag, rc) \ { \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_gm_module_t*)btl)->gm_frag_user, item, rc); \ frag = (mca_btl_gm_frag_t*) item; \ frag->my_list = &((mca_btl_gm_module_t*)btl)->gm_frag_user; \ @@ -103,7 +103,7 @@ OBJ_CLASS_DECLARATION(mca_btl_gm_frag_user_t); #define MCA_BTL_GM_FRAG_RETURN(btl, frag) \ { \ OMPI_FREE_LIST_RETURN(frag->my_list, \ - (opal_list_item_t*)(frag)); \ + (ompi_free_list_item_t*)(frag)); \ } diff --git a/ompi/mca/btl/mvapi/btl_mvapi.h b/ompi/mca/btl/mvapi/btl_mvapi.h index 6692c33fdc..c5931e60d8 100644 --- a/ompi/mca/btl/mvapi/btl_mvapi.h +++ b/ompi/mca/btl/mvapi/btl_mvapi.h @@ -245,7 +245,7 @@ struct mca_btl_mvapi_module_t { VAPI_ret_t ret; \ uint32_t rwqe_posted = 0; \ int rc; \ - opal_list_item_t* item = NULL; \ + ompi_free_list_item_t* item = NULL; \ mca_btl_mvapi_frag_t* frag = NULL; \ VAPI_rr_desc_t* desc_post = mvapi_btl->rr_desc_post; \ for(i = 0; i < cnt; i++) { \ diff --git a/ompi/mca/btl/mvapi/btl_mvapi_component.c b/ompi/mca/btl/mvapi/btl_mvapi_component.c index 4159a78f2e..5266336887 100644 --- a/ompi/mca/btl/mvapi/btl_mvapi_component.c +++ b/ompi/mca/btl/mvapi/btl_mvapi_component.c @@ -635,7 +635,7 @@ int mca_btl_mvapi_handle_incoming_hp( if (!MCA_BTL_MVAPI_RDMA_FRAG(frag)) { OMPI_FREE_LIST_RETURN(&(mvapi_btl->recv_free_eager), - (opal_list_item_t*) frag); + (ompi_free_list_item_t*) frag); } else { mca_btl_mvapi_frag_t *tf; OPAL_THREAD_LOCK(&endpoint->eager_rdma_local.lock); @@ -992,7 +992,7 @@ int mca_btl_mvapi_component_progress( void ) frag->hdr->tag, &frag->base, mvapi_btl->ib_reg[frag->hdr->tag].cbdata); - OMPI_FREE_LIST_RETURN(&(mvapi_btl->recv_free_max), (opal_list_item_t*) frag); + OMPI_FREE_LIST_RETURN(&(mvapi_btl->recv_free_max), (ompi_free_list_item_t*) frag); #ifdef VAPI_FEATURE_SRQ if(mca_btl_mvapi_component.use_srq) { diff --git a/ompi/mca/btl/mvapi/btl_mvapi_endpoint.h b/ompi/mca/btl/mvapi/btl_mvapi_endpoint.h index 25acd87520..c070f2bfaa 100644 --- a/ompi/mca/btl/mvapi/btl_mvapi_endpoint.h +++ b/ompi/mca/btl/mvapi/btl_mvapi_endpoint.h @@ -226,7 +226,7 @@ do { \ mca_btl_mvapi_module_t *mvapi_btl = my_endpoint->endpoint_btl; \ VAPI_rr_desc_t* desc_post = mvapi_btl->rr_desc_post; \ for(i = 0; i < num_post; i++) { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ mca_btl_mvapi_frag_t* frag = NULL; \ OMPI_FREE_LIST_WAIT(frag_list, item, rc); \ frag = (mca_btl_mvapi_frag_t*) item; \ diff --git a/ompi/mca/btl/mvapi/btl_mvapi_frag.h b/ompi/mca/btl/mvapi/btl_mvapi_frag.h index 89c651b27d..0a5ecdb7d7 100644 --- a/ompi/mca/btl/mvapi/btl_mvapi_frag.h +++ b/ompi/mca/btl/mvapi/btl_mvapi_frag.h @@ -134,7 +134,7 @@ OBJ_CLASS_DECLARATION(mca_btl_mvapi_recv_frag_max_t); #define MCA_BTL_IB_FRAG_ALLOC_EAGER(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_mvapi_module_t*)btl)->send_free_eager, item, rc); \ frag = (mca_btl_mvapi_frag_t*) item; \ frag->my_list = &((mca_btl_mvapi_module_t*)btl)->send_free_eager; \ @@ -143,7 +143,7 @@ OBJ_CLASS_DECLARATION(mca_btl_mvapi_recv_frag_max_t); #define MCA_BTL_IB_FRAG_ALLOC_MAX(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_mvapi_module_t*)btl)->send_free_max, item, rc); \ frag = (mca_btl_mvapi_frag_t*) item; \ frag->my_list = &((mca_btl_mvapi_module_t*)btl)->send_free_max; \ @@ -152,7 +152,7 @@ OBJ_CLASS_DECLARATION(mca_btl_mvapi_recv_frag_max_t); #define MCA_BTL_IB_FRAG_ALLOC_FRAG(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_mvapi_module_t*)btl)->send_free_frag, item, rc); \ frag = (mca_btl_mvapi_frag_t*) item; \ frag->my_list = &((mca_btl_mvapi_module_t*)btl)->send_free_frag; \ @@ -161,7 +161,7 @@ OBJ_CLASS_DECLARATION(mca_btl_mvapi_recv_frag_max_t); #define MCA_BTL_IB_FRAG_RETURN(btl, frag) \ { \ OMPI_FREE_LIST_RETURN(frag->my_list, \ - (opal_list_item_t*)(frag)); \ + (ompi_free_list_item_t*)(frag)); \ } diff --git a/ompi/mca/btl/mx/btl_mx_frag.h b/ompi/mca/btl/mx/btl_mx_frag.h index 7036858c74..a6eb79b3c3 100644 --- a/ompi/mca/btl/mx/btl_mx_frag.h +++ b/ompi/mca/btl/mx/btl_mx_frag.h @@ -67,7 +67,7 @@ extern "C" { #define MCA_BTL_MX_FRAG_ALLOC_EAGER(btl, frag, rc) \ { \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT( &mca_btl_mx_component.mx_send_eager_frags, item, rc); \ frag = (mca_btl_mx_frag_t*) item; \ frag->mx_frag_list = (ompi_free_list_t*)&(mca_btl_mx_component.mx_send_eager_frags); \ @@ -78,7 +78,7 @@ extern "C" { #if 0 #define MCA_BTL_MX_FRAG_ALLOC_USER(btl, frag, rc) \ { \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT( &mca_btl_mx_component.mx_send_user_frags, item, rc); \ frag = (mca_btl_mx_frag_t*) item; \ frag->mx_frag_list = (ompi_free_list_t*)&(mca_btl_mx_component.mx_send_user_frags); \ @@ -93,7 +93,7 @@ extern "C" { #define MCA_BTL_MX_FRAG_RETURN(btl, frag) \ { \ /*opal_output( 0, "return item to %p\n", frag->mx_frag_list );*/ \ - OMPI_FREE_LIST_RETURN( frag->mx_frag_list, (opal_list_item_t*)(frag)); \ + OMPI_FREE_LIST_RETURN( frag->mx_frag_list, (ompi_free_list_item_t*)(frag)); \ } #if defined(c_plusplus) || defined(__cplusplus) diff --git a/ompi/mca/btl/openib/btl_openib.h b/ompi/mca/btl/openib/btl_openib.h index d4fffa0c2d..7f13fe1607 100644 --- a/ompi/mca/btl/openib/btl_openib.h +++ b/ompi/mca/btl/openib/btl_openib.h @@ -463,7 +463,7 @@ int mca_btl_openib_module_init(mca_btl_openib_module_t* openib_btl); do { \ int32_t i; \ int32_t num_post = cnt; \ - opal_list_item_t* item = NULL; \ + ompi_free_list_item_t* item = NULL; \ mca_btl_openib_frag_t* frag = NULL; \ struct ibv_recv_wr *bad_wr; \ int32_t rc; \ diff --git a/ompi/mca/btl/openib/btl_openib_component.c b/ompi/mca/btl/openib/btl_openib_component.c index 1423c75b9d..bd7a7b4ff1 100644 --- a/ompi/mca/btl/openib/btl_openib_component.c +++ b/ompi/mca/btl/openib/btl_openib_component.c @@ -646,7 +646,7 @@ int mca_btl_openib_handle_incoming_hp( if (!MCA_BTL_OPENIB_RDMA_FRAG(frag)) { OMPI_FREE_LIST_RETURN(&(openib_btl->recv_free_eager), - (opal_list_item_t*) frag); + (ompi_free_list_item_t*) frag); } else { mca_btl_openib_frag_t *tf; OPAL_THREAD_LOCK(&endpoint->eager_rdma_local.lock); @@ -1101,7 +1101,7 @@ int mca_btl_openib_component_progress() frag->hdr->tag, &frag->base, openib_btl->ib_reg[frag->hdr->tag].cbdata); - OMPI_FREE_LIST_RETURN(&(openib_btl->recv_free_max), (opal_list_item_t*) frag); + OMPI_FREE_LIST_RETURN(&(openib_btl->recv_free_max), (ompi_free_list_item_t*) frag); #ifdef OMPI_MCA_BTL_OPENIB_HAVE_SRQ if(mca_btl_openib_component.use_srq) { diff --git a/ompi/mca/btl/openib/btl_openib_endpoint.h b/ompi/mca/btl/openib/btl_openib_endpoint.h index 1263a3f930..c59669b1dc 100644 --- a/ompi/mca/btl/openib/btl_openib_endpoint.h +++ b/ompi/mca/btl/openib/btl_openib_endpoint.h @@ -233,7 +233,7 @@ do { \ int32_t num_post = cnt; \ struct ibv_recv_wr* bad_wr; \ for(i = 0; i < num_post; i++) { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ mca_btl_openib_frag_t* frag; \ OMPI_FREE_LIST_WAIT(frag_list, item, rc); \ frag = (mca_btl_openib_frag_t*) item; \ diff --git a/ompi/mca/btl/openib/btl_openib_frag.h b/ompi/mca/btl/openib/btl_openib_frag.h index d1ad0272ec..ff107aeee9 100644 --- a/ompi/mca/btl/openib/btl_openib_frag.h +++ b/ompi/mca/btl/openib/btl_openib_frag.h @@ -130,7 +130,7 @@ OBJ_CLASS_DECLARATION(mca_btl_openib_recv_frag_max_t); #define MCA_BTL_IB_FRAG_ALLOC_EAGER(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_openib_module_t*)btl)->send_free_eager, item, rc); \ frag = (mca_btl_openib_frag_t*) item; \ } @@ -138,7 +138,7 @@ OBJ_CLASS_DECLARATION(mca_btl_openib_recv_frag_max_t); #define MCA_BTL_IB_FRAG_ALLOC_MAX(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_openib_module_t*)btl)->send_free_max, item, rc); \ frag = (mca_btl_openib_frag_t*) item; \ } @@ -146,7 +146,7 @@ OBJ_CLASS_DECLARATION(mca_btl_openib_recv_frag_max_t); #define MCA_BTL_IB_FRAG_ALLOC_FRAG(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_openib_module_t*)btl)->send_free_frag, item, rc); \ frag = (mca_btl_openib_frag_t*) item; \ } @@ -165,7 +165,7 @@ OBJ_CLASS_DECLARATION(mca_btl_openib_recv_frag_max_t); case MCA_BTL_OPENIB_FRAG_FRAG: \ my_list = &btl->send_free_frag; \ } \ - OMPI_FREE_LIST_RETURN(my_list, (opal_list_item_t*)(frag)); \ + OMPI_FREE_LIST_RETURN(my_list, (ompi_free_list_item_t*)(frag)); \ } while(0); \ } diff --git a/ompi/mca/btl/self/btl_self_frag.h b/ompi/mca/btl/self/btl_self_frag.h index 5a7d83024f..a4ccad3fd2 100644 --- a/ompi/mca/btl/self/btl_self_frag.h +++ b/ompi/mca/btl/self/btl_self_frag.h @@ -48,38 +48,39 @@ OBJ_CLASS_DECLARATION(mca_btl_self_frag_rdma_t); #define MCA_BTL_SELF_FRAG_ALLOC_EAGER(frag, rc) \ { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_btl_self_component.self_frags_eager, item, rc); \ frag = (mca_btl_self_frag_t*)item; \ } #define MCA_BTL_SELF_FRAG_RETURN_EAGER(frag) \ { \ - OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_eager, (opal_list_item_t*)(frag)); \ + OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_eager, \ + (ompi_free_list_item_t*)(frag)); \ } #define MCA_BTL_SELF_FRAG_ALLOC_SEND(frag, rc) \ { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_btl_self_component.self_frags_send, item, rc); \ frag = (mca_btl_self_frag_t*)item; \ } #define MCA_BTL_SELF_FRAG_RETURN_SEND(frag) \ { \ - OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_send, (opal_list_item_t*)(frag)); \ + OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_send, (ompi_free_list_item_t*)(frag)); \ } #define MCA_BTL_SELF_FRAG_ALLOC_RDMA(frag, rc) \ { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_btl_self_component.self_frags_rdma, item, rc); \ frag = (mca_btl_self_frag_t*)item; \ } #define MCA_BTL_SELF_FRAG_RETURN_RDMA(frag) \ { \ - OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_rdma, (opal_list_item_t*)(frag)); \ + OMPI_FREE_LIST_RETURN(&mca_btl_self_component.self_frags_rdma, (ompi_free_list_item_t*)(frag)); \ } #endif diff --git a/ompi/mca/btl/sm/btl_sm_frag.h b/ompi/mca/btl/sm/btl_sm_frag.h index 26549aaef2..db8b784aeb 100644 --- a/ompi/mca/btl/sm/btl_sm_frag.h +++ b/ompi/mca/btl/sm/btl_sm_frag.h @@ -59,7 +59,7 @@ OBJ_CLASS_DECLARATION(mca_btl_sm_frag2_t); #define MCA_BTL_SM_FRAG_ALLOC1(frag, rc) \ { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_btl_sm_component.sm_frags1, item, rc); \ frag = (mca_btl_sm_frag_t*)item; \ frag->my_list = &mca_btl_sm_component.sm_frags1; \ @@ -67,7 +67,7 @@ OBJ_CLASS_DECLARATION(mca_btl_sm_frag2_t); #define MCA_BTL_SM_FRAG_ALLOC2(frag, rc) \ { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_btl_sm_component.sm_frags2, item, rc); \ frag = (mca_btl_sm_frag_t*)item; \ frag->my_list = &mca_btl_sm_component.sm_frags2; \ @@ -75,7 +75,7 @@ OBJ_CLASS_DECLARATION(mca_btl_sm_frag2_t); #define MCA_BTL_SM_FRAG_RETURN(frag) \ { \ - OMPI_FREE_LIST_RETURN(frag->my_list, (opal_list_item_t*)(frag)); \ + OMPI_FREE_LIST_RETURN(frag->my_list, (ompi_free_list_item_t*)(frag)); \ } #endif diff --git a/ompi/mca/btl/tcp/btl_tcp_frag.h b/ompi/mca/btl/tcp/btl_tcp_frag.h index eb1d079bcb..9dc8890f7e 100644 --- a/ompi/mca/btl/tcp/btl_tcp_frag.h +++ b/ompi/mca/btl/tcp/btl_tcp_frag.h @@ -82,7 +82,7 @@ OBJ_CLASS_DECLARATION(mca_btl_tcp_frag_user_t); #define MCA_BTL_TCP_FRAG_ALLOC_EAGER(frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&mca_btl_tcp_component.tcp_frag_eager, item, rc); \ frag = (mca_btl_tcp_frag_t*) item; \ } @@ -90,14 +90,14 @@ OBJ_CLASS_DECLARATION(mca_btl_tcp_frag_user_t); #define MCA_BTL_TCP_FRAG_ALLOC_MAX(frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&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) \ { \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&mca_btl_tcp_component.tcp_frag_user, item, rc); \ frag = (mca_btl_tcp_frag_t*) item; \ } @@ -105,7 +105,7 @@ OBJ_CLASS_DECLARATION(mca_btl_tcp_frag_user_t); #define MCA_BTL_TCP_FRAG_RETURN(frag) \ { \ OMPI_FREE_LIST_RETURN(frag->my_list, \ - (opal_list_item_t*)(frag)); \ + (ompi_free_list_item_t*)(frag)); \ } #define MCA_BTL_TCP_FRAG_INIT_DST(frag,ep) \ diff --git a/ompi/mca/btl/template/btl_template_frag.h b/ompi/mca/btl/template/btl_template_frag.h index 393b05c5e4..00ed4d9edc 100644 --- a/ompi/mca/btl/template/btl_template_frag.h +++ b/ompi/mca/btl/template/btl_template_frag.h @@ -69,7 +69,7 @@ OBJ_CLASS_DECLARATION(mca_btl_template_frag_user_t); #define MCA_BTL_TEMPLATE_FRAG_ALLOC_EAGER(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_template_module_t*)btl)->template_frag_eager, item, rc); \ frag = (mca_btl_template_frag_t*) item; \ } @@ -77,13 +77,13 @@ OBJ_CLASS_DECLARATION(mca_btl_template_frag_user_t); #define MCA_BTL_TEMPLATE_FRAG_RETURN_EAGER(btl, frag) \ { \ OMPI_FREE_LIST_RETURN(&((mca_btl_template_module_t*)btl)->template_frag_eager, \ - (opal_list_item_t*)(frag)); \ + (ompi_free_list_item_t*)(frag)); \ } #define MCA_BTL_TEMPLATE_FRAG_ALLOC_MAX(btl, frag, rc) \ { \ \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_template_module_t*)btl)->template_frag_max, item, rc); \ frag = (mca_btl_template_frag_t*) item; \ } @@ -91,13 +91,13 @@ OBJ_CLASS_DECLARATION(mca_btl_template_frag_user_t); #define MCA_BTL_TEMPLATE_FRAG_RETURN_MAX(btl, frag) \ { \ OMPI_FREE_LIST_RETURN(&((mca_btl_template_module_t*)btl)->template_frag_max, \ - (opal_list_item_t*)(frag)); \ + (ompi_free_list_item_t*)(frag)); \ } #define MCA_BTL_TEMPLATE_FRAG_ALLOC_USER(btl, frag, rc) \ { \ - opal_list_item_t *item; \ + ompi_free_list_item_t *item; \ OMPI_FREE_LIST_WAIT(&((mca_btl_template_module_t*)btl)->template_frag_user, item, rc); \ frag = (mca_btl_template_frag_t*) item; \ } @@ -105,7 +105,7 @@ OBJ_CLASS_DECLARATION(mca_btl_template_frag_user_t); #define MCA_BTL_TEMPLATE_FRAG_RETURN_USER(btl, frag) \ { \ OMPI_FREE_LIST_RETURN(&((mca_btl_template_module_t*)btl)->template_frag_user, \ - (opal_list_item_t*)(frag)); \ + (ompi_free_list_item_t*)(frag)); \ } diff --git a/ompi/mca/io/base/io_base_request.c b/ompi/mca/io/base/io_base_request.c index ccde44324a..eecc76b6a8 100644 --- a/ompi/mca/io/base/io_base_request.c +++ b/ompi/mca/io/base/io_base_request.c @@ -222,10 +222,11 @@ void mca_io_base_request_free(ompi_file_t *file, */ void mca_io_base_request_return(ompi_file_t *file) { - opal_list_item_t *next; + ompi_free_list_item_t *next; OPAL_THREAD_LOCK(&file->f_io_requests_lock); - while (NULL != (next = opal_list_remove_first(&file->f_io_requests))) { + while (NULL != (next = (ompi_free_list_item_t*) + opal_list_remove_first(&file->f_io_requests))) { OMPI_FREE_LIST_RETURN(&mca_io_base_requests, next); } OPAL_THREAD_UNLOCK(&file->f_io_requests_lock); diff --git a/ompi/mca/pml/dr/pml_dr_recvfrag.h b/ompi/mca/pml/dr/pml_dr_recvfrag.h index c1cdfe6f9e..354bf11afd 100644 --- a/ompi/mca/pml/dr/pml_dr_recvfrag.h +++ b/ompi/mca/pml/dr/pml_dr_recvfrag.h @@ -54,7 +54,7 @@ OBJ_CLASS_DECLARATION(mca_pml_dr_recv_frag_t); #define MCA_PML_DR_RECV_FRAG_ALLOC(frag,rc) \ do { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_pml_dr.recv_frags, item, rc); \ frag = (mca_pml_dr_recv_frag_t*)item; \ } while(0) @@ -77,7 +77,7 @@ do { \ \ /* copy over data */ \ for(i=0; inum_segments; i++) { \ OMPI_FREE_LIST_RETURN(&mca_pml_dr.buffers, \ - (opal_list_item_t*)frag->buffers[i]); \ + (ompi_free_list_item_t*)frag->buffers[i]); \ } \ frag->num_segments = 0; \ \ /* return recv_frag */ \ OMPI_FREE_LIST_RETURN(&mca_pml_dr.recv_frags, \ - (opal_list_item_t*)frag); \ + (ompi_free_list_item_t*)frag); \ } while(0) diff --git a/ompi/mca/pml/dr/pml_dr_recvreq.h b/ompi/mca/pml/dr/pml_dr_recvreq.h index 8c409623c9..d5dc779f74 100644 --- a/ompi/mca/pml/dr/pml_dr_recvreq.h +++ b/ompi/mca/pml/dr/pml_dr_recvreq.h @@ -114,16 +114,18 @@ do { \ #define MCA_PML_DR_RECV_REQUEST_PML_COMPLETE(recvreq) \ do { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ assert( false == recvreq->req_recv.req_base.req_pml_complete ); \ OPAL_THREAD_LOCK((recvreq)->req_mutex); \ - while(NULL != (item = opal_list_remove_first(&(recvreq)->req_vfrags))) { \ + while(NULL != (item = (ompi_free_list_item_t*) \ + opal_list_remove_first(&(recvreq)->req_vfrags))) { \ OMPI_FREE_LIST_RETURN(&mca_pml_dr.vfrags, item); \ } \ OPAL_THREAD_UNLOCK((recvreq)->req_mutex); \ \ OPAL_THREAD_LOCK(&ompi_request_lock); \ - opal_list_remove_item(&(recvreq)->req_proc->matched_receives, (opal_list_item_t*)(recvreq)); \ + opal_list_remove_item(&(recvreq)->req_proc->matched_receives, \ + (opal_list_item_t*)(recvreq)); \ \ /* initialize request status */ \ recvreq->req_recv.req_base.req_pml_complete = true; \ @@ -148,7 +150,7 @@ do { do { \ /* decrement reference counts */ \ MCA_PML_BASE_RECV_REQUEST_FINI(&(recvreq)->req_recv); \ - OMPI_FREE_LIST_RETURN(&mca_pml_dr.recv_requests, (opal_list_item_t*)(recvreq)); \ + OMPI_FREE_LIST_RETURN(&mca_pml_dr.recv_requests, (ompi_free_list_item_t*)(recvreq)); \ } while(0) /** diff --git a/ompi/mca/pml/dr/pml_dr_sendreq.h b/ompi/mca/pml/dr/pml_dr_sendreq.h index 48bd75cbd1..d8599a7765 100644 --- a/ompi/mca/pml/dr/pml_dr_sendreq.h +++ b/ompi/mca/pml/dr/pml_dr_sendreq.h @@ -75,7 +75,7 @@ OBJ_CLASS_DECLARATION(mca_pml_dr_send_request_t); { \ ompi_proc_t *proc = \ comm->c_pml_procs[dst]->proc_ompi; \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ \ if(NULL == proc) { \ rc = OMPI_ERR_OUT_OF_RESOURCE; \ @@ -267,7 +267,7 @@ do { /* Let the base handle the reference counts */ \ MCA_PML_BASE_SEND_REQUEST_FINI((&(sendreq)->req_send)); \ OMPI_FREE_LIST_RETURN( &mca_pml_dr.send_requests, \ - (opal_list_item_t*)sendreq ); \ + (ompi_free_list_item_t*)sendreq ); \ } while(0) /* diff --git a/ompi/mca/pml/dr/pml_dr_vfrag.h b/ompi/mca/pml/dr/pml_dr_vfrag.h index c80083a173..9029dc4e21 100644 --- a/ompi/mca/pml/dr/pml_dr_vfrag.h +++ b/ompi/mca/pml/dr/pml_dr_vfrag.h @@ -68,7 +68,7 @@ OBJ_CLASS_DECLARATION(mca_pml_dr_vfrag_t); #define MCA_PML_DR_VFRAG_ALLOC(vfrag,rc) \ do { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_pml_dr.vfrags, item, rc); \ vfrag = (mca_pml_dr_vfrag_t*)item; \ } while(0) @@ -76,7 +76,8 @@ do { \ #define MCA_PML_DR_VFRAG_RETURN(vfrag) \ do { \ - OMPI_FREE_LIST_RETURN(&mca_pml_dr.vfrags, (opal_list_item_t*)vfrag); \ + OMPI_FREE_LIST_RETURN(&mca_pml_dr.vfrags, \ + (ompi_free_list_item_t*)vfrag); \ } while(0) #define MCA_PML_DR_VFRAG_INIT(vfrag) \ diff --git a/ompi/mca/pml/ob1/pml_ob1_rdmafrag.h b/ompi/mca/pml/ob1/pml_ob1_rdmafrag.h index c8dad8e59e..d4ac2517e6 100644 --- a/ompi/mca/pml/ob1/pml_ob1_rdmafrag.h +++ b/ompi/mca/pml/ob1/pml_ob1_rdmafrag.h @@ -50,7 +50,7 @@ OBJ_CLASS_DECLARATION(mca_pml_ob1_rdma_frag_t); #define MCA_PML_OB1_RDMA_FRAG_ALLOC(frag,rc) \ do { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_pml_ob1.rdma_frags, item, rc); \ frag = (mca_pml_ob1_rdma_frag_t*)item; \ } while(0) @@ -59,7 +59,7 @@ do { \ do { \ /* return fragment */ \ OMPI_FREE_LIST_RETURN(&mca_pml_ob1.rdma_frags, \ - (opal_list_item_t*)frag); \ + (ompi_free_list_item_t*)frag); \ } while(0) diff --git a/ompi/mca/pml/ob1/pml_ob1_recvfrag.h b/ompi/mca/pml/ob1/pml_ob1_recvfrag.h index eee5c0e6fc..e0fc83b41e 100644 --- a/ompi/mca/pml/ob1/pml_ob1_recvfrag.h +++ b/ompi/mca/pml/ob1/pml_ob1_recvfrag.h @@ -52,7 +52,7 @@ OBJ_CLASS_DECLARATION(mca_pml_ob1_recv_frag_t); #define MCA_PML_OB1_RECV_FRAG_ALLOC(frag,rc) \ do { \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ OMPI_FREE_LIST_WAIT(&mca_pml_ob1.recv_frags, item, rc); \ frag = (mca_pml_ob1_recv_frag_t*)item; \ } while(0) @@ -70,7 +70,7 @@ do { \ frag->num_segments = cnt; \ /* copy over data */ \ for(i=0; inum_segments; i++) { \ OMPI_FREE_LIST_RETURN(&mca_pml_ob1.buffers, \ - (opal_list_item_t*)frag->buffers[i]); \ + (ompi_free_list_item_t*)frag->buffers[i]); \ } \ frag->num_segments = 0; \ \ /* return recv_frag */ \ OMPI_FREE_LIST_RETURN(&mca_pml_ob1.recv_frags, \ - (opal_list_item_t*)frag); \ + (ompi_free_list_item_t*)frag); \ } while(0) diff --git a/ompi/mca/pml/ob1/pml_ob1_recvreq.h b/ompi/mca/pml/ob1/pml_ob1_recvreq.h index 3c3ca5c79d..3f8eb5701c 100644 --- a/ompi/mca/pml/ob1/pml_ob1_recvreq.h +++ b/ompi/mca/pml/ob1/pml_ob1_recvreq.h @@ -172,7 +172,7 @@ do { { \ MCA_PML_BASE_RECV_REQUEST_FINI(&(recvreq)->req_recv); \ OMPI_FREE_LIST_RETURN( &mca_pml_ob1.recv_requests, \ - (opal_list_item_t*)(recvreq)); \ + (ompi_free_list_item_t*)(recvreq)); \ } /** diff --git a/ompi/mca/pml/ob1/pml_ob1_sendreq.h b/ompi/mca/pml/ob1/pml_ob1_sendreq.h index 9e8d40cd06..d8f89e6f92 100644 --- a/ompi/mca/pml/ob1/pml_ob1_sendreq.h +++ b/ompi/mca/pml/ob1/pml_ob1_sendreq.h @@ -69,7 +69,7 @@ OBJ_CLASS_DECLARATION(mca_pml_ob1_send_request_t); { \ ompi_proc_t *proc = \ comm->c_pml_procs[dst]->proc_ompi; \ - opal_list_item_t* item; \ + ompi_free_list_item_t* item; \ \ if(NULL == proc) { \ rc = OMPI_ERR_OUT_OF_RESOURCE; \ @@ -336,7 +336,7 @@ do { /* Let the base handle the reference counts */ \ MCA_PML_BASE_SEND_REQUEST_FINI((&(sendreq)->req_send)); \ OMPI_FREE_LIST_RETURN( \ - &mca_pml_ob1.send_requests, (opal_list_item_t*)sendreq); \ + &mca_pml_ob1.send_requests, (ompi_free_list_item_t*)sendreq); \ } /* diff --git a/ompi/mca/rcache/rb/rcache_rb_tree.c b/ompi/mca/rcache/rb/rcache_rb_tree.c index 2a8300c15b..6b226365bb 100644 --- a/ompi/mca/rcache/rb/rcache_rb_tree.c +++ b/ompi/mca/rcache/rb/rcache_rb_tree.c @@ -151,7 +151,8 @@ int mca_rcache_rb_tree_delete(mca_rcache_rb_module_t* rb_module, assert(reg == tree_item->reg); rc = ompi_rb_tree_delete(&rb_module->rb_tree, &tree_item->key); - OMPI_FREE_LIST_RETURN(&rb_module->rb_tree_item_list, (opal_list_item_t*) tree_item); + OMPI_FREE_LIST_RETURN(&rb_module->rb_tree_item_list, + (ompi_free_list_item_t*) tree_item); return rc; }