Open MPI logo

Open MPI Development Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Development mailing list

Subject: Re: [OMPI devel] RFC : what is the best way to fix the memory leak in mca/pml/bfo
From: George Bosilca (bosilca_at_[hidden])
Date: 2014-05-16 12:33:15

Here is the patch for ob1. It was laying in one of my branches for
quite some time, it was slightly tested. What was not tested at all is
the MTL interaction.


On Fri, May 16, 2014 at 9:14 AM, Rolf vandeVaart <rvandevaart_at_[hidden]> wrote:
> The bfo PML is mostly a duplicate of the ob1 PML but with extra code to handle failover when running with a cluster with multiple IB NICs. A few observations.
> 1. Almost no one uses the bfo PML. I have kept it around just in case someone thinks about failover again.
> 2. The code where you are saying there is a leak is a duplicate of what is in ob1. So if memory is not supposed to be allocated in the "open" call, then this is an issue for the ob1 PML as well.
> So, we could go forward in a few ways.
> 1. Just apply your first patch as that seems to fit what Ralph is saying. And leave ob1 alone.
> 2. Fix it in both bfo and ob1. But needs more testing as ob1 is critical.
> Rolf
>>-----Original Message-----
>>From: devel [mailto:devel-bounces_at_[hidden]] On Behalf Of Ralph
>>Sent: Friday, May 16, 2014 8:54 AM
>>To: Open MPI Developers
>>Subject: Re: [OMPI devel] RFC : what is the best way to fix the memory leak in
>>Memory isn't supposed to allocated in the "open" call, but only after the
>>component is selected (and thus in the "init" call").
>>On May 15, 2014, at 10:57 PM, Gilles Gouaillardet
>><gilles.gouaillardet_at_[hidden]> wrote:
>>> Folks,
>>> there is a small memory leak in ompi/mca/pml/bfo/pml_bfo_component.c
>>> in my environment, this module is not used.
>>> this means mca_pml_bfo_component_open() and
>>> mca_pml_bfo_component_close() are invoked but
>>> mca_pml_bfo_component_init() and mca_pml_bfo_component_fini() are
>>*not* invoked.
>>> mca_pml_bfo.allocator is currently allocated in
>>> mca_pml_bfo_component_open() and released in
>>> mca_pml_bfo_component_fini() this causes a leak (at least in my
>>> environment, since mca_pml_bfo_component_fini() is not invoked)
>>> One option is to release the allocator in
>>> mca_pml_bfo_component_close() An other option is to allocate the
>>> allocator in mca_pml_bfo_component_init()
>>> Which is the correct/best one ?
>>> i attached two patches, which one (if any) should be commited ?
>>> Thanks in advance for your insights
>>> Gilles
>>> ______________________________
>>> devel mailing list
>>> devel_at_[hidden]
>>> Subscription:
>>> Link to this post:
>>devel mailing list
>>Link to this post:
> -----------------------------------------------------------------------------------
> This email message is for the sole use of the intended recipient(s) and may contain
> confidential information. Any unauthorized review, use, disclosure or distribution
> is prohibited. If you are not the intended recipient, please contact the sender by
> reply email and destroy all copies of the original message.
> -----------------------------------------------------------------------------------
> _______________________________________________
> devel mailing list
> devel_at_[hidden]
> Subscription:
> Link to this post: