I want to change a large Fortran 90 program to use double precision instead of single precision. I thought the easiest way to do this is to add the following flag to the compiler:
-fdefault-real-8
However, this does not seem to update the MPI commands. For example, I need to change commands like this:
CALL MPI_RECV(x, n, MPI_REAL, rankstart, tag, comm, stat, ierr)
to
CALL MPI_RECV(x, n, MPI_REAL8, rankstart, tag, comm, stat, ierr)
Do you know if there is a compiler flag to change the default value of MPI_REAL
to MPI_REAL8
? If not, do you know of another way I can easily change the precision of the program without having the manually adjust all the commands in the code myself?