From 5596aa5f53e3549004de608238192548e7e7b73b Mon Sep 17 00:00:00 2001 From: Gleb Natapov Date: Mon, 20 Aug 2007 12:06:27 +0000 Subject: [PATCH] The sizes of mca_pml_ob1_send_request_t and mca_pml_ob1_recv_request_t depend on a parameter and are determined in runtime. r15346 removed calculation of correct sizes for this structures. This patch adds it back and fixes trac:1116, #1114. This commit was SVN r15932. The following SVN revision numbers were found above: r15346 --> open-mpi/ompi@433f8a7694ccb7c40fdf0551abb31fe484f81484 The following Trac tickets were found above: Ticket 1116 --> https://svn.open-mpi.org/trac/ompi/ticket/1116 --- ompi/mca/pml/ob1/pml_ob1.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ompi/mca/pml/ob1/pml_ob1.c b/ompi/mca/pml/ob1/pml_ob1.c index 75f8c8d86e..586a777b40 100644 --- a/ompi/mca/pml/ob1/pml_ob1.c +++ b/ompi/mca/pml/ob1/pml_ob1.c @@ -132,7 +132,9 @@ int mca_pml_ob1_enable(bool enable) * initialize them with the size of our own requests. */ ompi_free_list_init( &mca_pml_base_send_requests, - sizeof(mca_pml_ob1_send_request_t), + sizeof(mca_pml_ob1_send_request_t) + + (mca_pml_ob1.max_rdma_per_request - 1) * + sizeof(mca_pml_ob1_com_btl_t), OBJ_CLASS(mca_pml_ob1_send_request_t), mca_pml_ob1.free_list_num, mca_pml_ob1.free_list_max, @@ -140,7 +142,9 @@ int mca_pml_ob1_enable(bool enable) NULL ); ompi_free_list_init( &mca_pml_base_recv_requests, - sizeof(mca_pml_ob1_recv_request_t), + sizeof(mca_pml_ob1_recv_request_t) + + (mca_pml_ob1.max_rdma_per_request - 1) * + sizeof(mca_pml_ob1_com_btl_t), OBJ_CLASS(mca_pml_ob1_recv_request_t), mca_pml_ob1.free_list_num, mca_pml_ob1.free_list_max,