Newsgroups: comp.parallel.mpi
From: salo@mrjones.engr.sgi.com (Eric Salo)
Subject: Re: Two question abort MPI
Organization: Silicon Graphics, Inc.  Mountain View, CA
Date: 23 Apr 1996 15:54:50 GMT
Message-ID: <4liuga$a06@murrow.corp.sgi.com>

> 1) I want to know if it is possible to send a signal to a processor to
> indicate that a message is arrived and have to be recieved?

This is not currently possible, but it looks likely that MPI-2 will define
some sort of interface which would allow you to invoke a handler function
upon receiving a message.

> My project - Parallell Recursive Procedure - is based on a
> client-server model. Presently I solve the problem of the client
> checking the messagebuffer by frequently calls to the MPI_Iprobe
> function. It will be more effective if a signal can be send to remind
> the client that a server has send a message. Could someone tell me how
> can I do this in MPI?

If your client process has useful work that it might be doing until a new
message arrives, then this is the proper algorithm to be using. If not, then
it could simply call MPI_Wait. A high-quality MPI implementation might then
put the process to sleep after some period of time if it determines that there
are no new incoming messages.

> Is it possible to send an array as a pointer at all?

You can't create a datatype that includes a pointer and have MPI
automatically dereference it for you. However, once you do allocate a
buffer, you could (I think) build a new datatype using MPI_BOTTOM that
would contain the contents of that buffer. I'll defer to others on this
point, since I've never personally used MPI_BOTTOM.

Eric Salo         Silicon Graphics Inc.             "Do you know what the
(415)933-2998     2011 N. Shoreline Blvd, 7L-802     last Xon said, just
salo@sgi.com      Mountain View, CA   94043-1389     before he died?"

