Open MPI logo

Open MPI User's Mailing List Archives

  |   Home   |   Support   |   FAQ   |   all Open MPI User's mailing list

Subject: Re: [OMPI users] Pinned memory
From: Brian W. Barrett (brbarret_at_[hidden])
Date: 2009-01-30 13:24:25

On Thu, 29 Jan 2009, Gabriele Fatigati wrote:

> Dear OpenMPI Developer,
> i have a doubt regards mpi_leave_pinned parameter. Suppose i have a simple for:
> for( int i=0; i< 100; i++)
> MPI_Reduce(a, b, .......)
> My question is: if i set mpi_leave_pinned= 1, buffer memories are
> pinned in the entire process, or just into the for cycle?
> When the cycle is finished, a and b memories, are unregistrered?

When mpi_leave_pinned is set to 1, any memory used in long message
communication is pinned until it is released back to the OS, the MPI has
to unpin it in order to pin some other memory, or until MPI_Finalize,
whichever comes first.

Note that a and b might never have been pinned in your example, if they
are short buffers, as the copy protocol is always used for short messages.