Newsgroups: comp.parallel.mpi
From: furnish@dino.ph.utexas.edu (Geoffrey Furnish)
Subject: Re: MPI_Finalize necessary ?
Organization: Institute for Fusion Studies, University of Texas at Austin
Date: 05 Sep 1995 18:25:13 GMT
Message-ID: <FURNISH.95Sep5132513@dino.ph.utexas.edu>

In article <Pine.LNX.3.91.950904121012.11333B-100000@mortar.fit.qut.edu.au> "Thomas E. Koch" <koch@mortar.fit.qut.edu.au> writes:

> From: "Thomas E. Koch" <koch@mortar.fit.qut.edu.au>

> I just implemented Modula-2 and Oberon interface modules to MPI, using 
> MPICH, on a SP2 and a network of Linux PCs.
> In order to get better programming style I would like to put MPI_Init in 
> the body of these interface modules (initialization with import) and get 
> rid of MPI_Finalize. 
> So a user of these modules has not to care about this stuff.

> Is a MPI_Finalize essential ?

I am not familiar with either MOdula-2 or Oberon.  Do neither of these
languages provide a termination equivalent to whatever their
initiation concept is?  For example, in C++, you could easily imagine
an MPI parallel framework class along the lines of:

class MPI_App {
...
public:
    MPI_App(...) {
	MPI_Init(...);
    }
    ~MPI_App() {
	MPI_Finalize();
    }
};

(with other methods to suit your model, of course).  In this way, a
C++ user would not have to know anything about MPI_Finalize either,
since it is handled automatically in the application destructor.

Do Modula-2 and Oberon have no compatible language capability?  That
would certainly surprise me.

-- 
--
Geoffrey Furnish                  http://dino.ph.utexas.edu/~furnish
UT Institute for Fusion Studies,  furnish@dino.ph.utexas.edu   512-471-6147

	"Pushing back the boundary of inanity."

