Hi,
I was trying to use
flush(5)
read(*,*) x
in Fortran to read a value into x in a MPI program. I let processor 0 to read this value and other processors will execution a mpi_barrier to wait for processor 0. The program supposed to stop that this command to wait for input from keyboard, but it didn't. I used flush(5) to clear up the input buffer before this read command.
Then I reboot the lam-mpi, the program becomes normal, i.e., it stops at this command to wait for input from keyboard. Do you guys know why this is the case? Shall I add anything MPI related flush function?
Thank you.
Yeliang
|