- #1
pachomba
- 3
- 0
Hello,
I am trying to get the parameter MPI_TAG_UB for openmpi (I am using version 2.1.1). I know I need to use the routine MPI_COMM_GET_ATTR, but I have no idea how to do that, I never used fortran in my life. Following this link (https://www.mpi-forum.org/docs/mpi-2.2/mpi22-report/node369.htm) I tried this:
LOGICAL FLAG
INTEGER IERR
INTEGER (KIND=MPI_ADDRESS_KIND) VALUE
! Upon successful return, VALUE == 7 (sign extended)
CALL MPI_COMM_GET_ATTR(MPI_COMM_WORLD, KEYVAL, VALUE, FLAG, IERR)
I put that in a file test.f90, then did gfortran test.f90 -o test.out, but I got this error message:
Error: Parameter 'mpi_address_kind' at (1) has not been declared or is a variable, which does not reduce to a constant expression
Error: Unexpected end of file in 'test.f90'
So I have no idea what I'm doing. Did someone ever retrieved the value of MPI_TAG_UB for some MPI implementation?
Thanks!
I am trying to get the parameter MPI_TAG_UB for openmpi (I am using version 2.1.1). I know I need to use the routine MPI_COMM_GET_ATTR, but I have no idea how to do that, I never used fortran in my life. Following this link (https://www.mpi-forum.org/docs/mpi-2.2/mpi22-report/node369.htm) I tried this:
LOGICAL FLAG
INTEGER IERR
INTEGER (KIND=MPI_ADDRESS_KIND) VALUE
! Upon successful return, VALUE == 7 (sign extended)
CALL MPI_COMM_GET_ATTR(MPI_COMM_WORLD, KEYVAL, VALUE, FLAG, IERR)
I put that in a file test.f90, then did gfortran test.f90 -o test.out, but I got this error message:
Error: Parameter 'mpi_address_kind' at (1) has not been declared or is a variable, which does not reduce to a constant expression
Error: Unexpected end of file in 'test.f90'
So I have no idea what I'm doing. Did someone ever retrieved the value of MPI_TAG_UB for some MPI implementation?
Thanks!