Discussion:
Using MPI...
(too old to reply)
A***@gmail.com
2007-11-14 16:59:13 UTC
Permalink
Hi,

I have a application that allows you to hook up external DLL for
functionality. I want to create an external DLL that uses MPI. So,
is it possible for me to call MPI_Init inside the dll as opposed to
the main application. This would be equivalent to me calling a
function inside the application. It can be executed multiple times:


int my_mpi_function ()
{
MPI_Init....();

}
A***@gmail.com
2007-11-14 17:12:07 UTC
Permalink
Never mind, found that you can only call MPI_Init once and only once
Heiko Bauke
2007-11-14 17:28:10 UTC
Permalink
Hi,

On Wed, 14 Nov 2007 09:12:07 -0800
Post by A***@gmail.com
Never mind, found that you can only call MPI_Init once and only once
you can test if MPI_Init has already been called by MPI_Initialized, see
http://www.mpi-forum.org/docs/mpi-11-html/node151.html


Heiko
--
-- Gefährlicher als eine falsche Theorie ist eine richtige
-- in falschen Händen. (Gabriel Laub)
-- Cluster Computing @ http://www.clustercomputing.de
-- Heiko Bauke @ http://www.mpi-hd.mpg.de/personalhomes/bauke
David Cronk
2007-11-26 16:40:43 UTC
Permalink
You can call MPI_Init from anywhere, but only once. For this type of
situation you may want to do:

MPI_Initialized (&flag);
if (!flag)
MPI_Init ();

This ensures you only call MPI_Init once.

Hope this helps.

Dave.
Post by A***@gmail.com
Hi,
I have a application that allows you to hook up external DLL for
functionality. I want to create an external DLL that uses MPI. So,
is it possible for me to call MPI_Init inside the dll as opposed to
the main application. This would be equivalent to me calling a
int my_mpi_function ()
{
MPI_Init....();
}
--
Dr. David Cronk, Ph.D. phone: (865) 974-3735
Research Director fax: (865) 974-8296
Innovative Computing Lab http://www.cs.utk.edu/~cronk
University of Tennessee, Knoxville
Loading...