I want to write a program which at some point sleeps waiting for an
i/o event - receiving a message through mpi OR from normal file
descriptor (pipe for example). The question is how to do it nicely? For
using functions such as select or poll I would have to know on which fd
does MPI listen (maybe there is a function in mpi which returns fd?). On
the other hand the MPI_Recv function doesn't return when something waits
for reading in the pipe (non-mpi fd). At the moment I use select with a timeout, when
it returns i check non-blocking MPI_Recv and then call select again and
so on. But this is very ugly :(
If someone knows a better solution please let me know
best regards
p.
--
|