secretyv

openf95, OpenMP and dummy procedures

Discussion created by secretyv on Mar 18, 2010
Latest reply on Jul 7, 2010 by Rasale
openf95 4.2.1 fails to compile code that passes on gcc, intel and sun

Hello all,

I am strugling with the attached  exemple code that I am not able to compile. Error message complains about dummy procedure F beeing not shared.

Compiler version 4.2.1 or 4.2.3.1

[secretyv@lachine bug]$ /opt/open64/open64-4.2.3.1/bin/openf95 -c -mp a.F

         CALL F()
              ^   
openf95-1041 openf95: ERROR S2, File = a.F, Line = 21, Column = 15
  Dummy procedure "F" is called within a parallel region and must be in the shared list if autoscope is not specified.

openf95: Open64 Fortran Version 4.2.3.1 (f14) Thu Mar 18, 2010  16:04:34
openf95: 26 source lines
openf95: 1 Error(s), 0 Warning(s), 0 Other message(s), 0 ANSI(s)
openf95: "explain openf95-message number" gives more information about each message

 

The code exemple is reduced from a much larger code that does compile with OpenMP on gcc, intel and sun compilers on both Linux and windows platform.

Any help will be appreciated

Yves

SUBROUTINE S1(F) EXTERNAL F INTEGER L !$omp parallel shared(F) private(L) CALL S2(L, F) !$omp end parallel RETURN END C----------------------------------- SUBROUTINE S2(L, F) INTEGER L EXTERNAL F INTEGER I !$omp do DO I=1,L CALL F() ENDDO !$omp end do RETURN END

Outcomes