Changing the number of processors at runtime in parallel MPI programming.

I am using MPI-based concurrent programming in FORTRAN. To start a program, e.g. 10 processors I use the standard MPI command

mpirun -n 10 prog_name

Thus, the program will run on 10 processors from start to finish, that is, the number of processors is constant during code execution.

My question is that you can change the number of processors during program execution, for example. to start with two processors, then by some criteria I want to change the number of processors by 4, and then by 6-10 to 20 and so on.

Thanks in advance.

+1
source share
1 answer

MPI-2 () ​​, Google - mpi_comm_spawn . , , , MPI , . mpi_comm_get_attr mpi_universe_size, , , .

, .

, , , , 10 10 , 20 10 .

+8

All Articles