virtual action in pnetcdf

Latham, Robert J. robl at mcs.anl.gov
Fri Jun 15 09:55:20 CDT 2018


On Fri, 2018-06-15 at 10:58 +0200, Patrick Marsaleix wrote:
> Hello
> 
> I use pnetcdf. In my program, all the cores perform the same
> operations simultaneously, for example
> 
> status=nfmpi_put_vara_real_all(ncid,varid,start,edge,anyvar3d)
> 
> I wish now that some cores do not perform this operation (or
> transforms it as a virtual operation), but in my program this results
> in immobilizing the mpi process. Is there a way to do it?

You have a few options.  Here are my suggestions in decending order of
"goodness" (best idea first):

- Every process in the communicator must call the routine, but not
every process needs to contribute I/O.  The processes that you do not
wish to do anything should pass an 'edge' array of all zeros.

- Instead of COMM_WORLD, create a sub-communicator containing only the
participating processes.

- Wrap the call with begin_indep / end_indep -- you will likely see
very poor performance, but it won't hang.

==rob


More information about the parallel-netcdf mailing list