Re: MPI_SPAWN

Suresh Damodaran-Kamal (suresh@lanl.gov)
Fri, 20 Oct 1995 16:54:42 -0600

> >
> > The new dynamic spawn document does away with interfaces to
> > resource managers altogether. However, the document
> > says that "complex interaction of an MPI application with its runtime
> > environment should be done through an environment specific API."
> >

> I agree it is a barrier to portability. One solution
> to the portability problem is to specify the interface
> explicitly.
> I personally suspect this is impossible to do in a way that
> works well with *all* (or even most) runtime environments.
> If it's possible, then what we need is a specific proposal
> to think about.

OK, how about the following proposal:

MPI_SPAWN() has to call a runtime interface function to
physically spawn processes. How about standardizing at this level
for flexibility sake?

In this scenario, MPI_SPAWN() will take two
additional arguments which are a function pointer, and a null terminated list
containing arguments to this function.
This function, lets call it spawn_fn, will return a null terminated
list of IDs corresponding to each new process spawned.
spawn_fn will also take the following arguments by default, in addition to the
arguments passed specifically for spawn_fn, thru the MPI_SPAWN()
interface: "executable, arguments,n"
spawn_fn will in turn call the resource manager for
each environment, and has to be implemented by each environment.

If spawn_fn is nonNULL, MPI_SPAWN() will call spawn_fn() to do the
physical spawning, and use the returned IDs for book keeping.
The use of spawn_fn() frees the resource manager interface
from doing the MPI specific chores such as keeping track of groups etc.

-Suresh