Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29359 Discussions

Is it necessary to update the compiler?

z_wang
Beginner
488 Views

Dear Moderator,

I can succeed in compiling the program below only if I delete 'USE IMSL_LIBRARIES', otherwise the RAND() can't pass the compiler. Do you know why?

Besides, when it is run(without ''USE IMSL_LIBRARIES''), there also problem shows up with the warning,

"This application has failed to start because imsl_dll.dll was not found. Re-installing the application may fix this problem."

and then it stoped.

BLOCK DATA MPIPRIV_DEF
COMMON /MPIPRIV/ DUMMY
!DEC$ ATTRIBUTES ALIAS:"__imp__MPIPRIV" :: /MPIPRIV/
END BLOCK DATA MPIPRIV_DEF

PROGRAM Main
INCLUDE 'link_f90_static.h'
INCLUDE 'link_f90_dll.h'
USE IMSL_LIBRARIES! Only passed bycanceling this one
USE RNNOA_INT
USE IFPORT
IMPLICIT NONE
INTEGER :: I
REAL(8) :: norm_vector(5)
REAL :: U
! ------------
U = RAND()
WRITE(*,*) U
! --------
CALL RNNOA(norm_vector)
WRITE(*,*) (norm_vector(I), I=1,5)

END PROGRAM Main

I don't know how to update my compiler at hand.

Regards,

James

0 Kudos
1 Reply
Steven_L_Intel1
Employee
488 Views

Remove this line:

INCLUDE 'link_f90_dll.h'

The one with link_f90_static.h is sufficient. The extra one causes your program to be linked to the DLL form of the libraries and when your product was installed you did not select the option to update the system environment variables, so the IMSL DLLs are not on PATH.

You also should not have both USE IMSL_LIBRARIES and USE RNNOA_INT. You can use just IMSL_LIBRARIES, but that defines all the IMSL routines and may cause conflicts with routines you didn't intend to come from IMSL - such as RAND in this case. It also slows down compilation a lot to use such a large module. Remove the USE IMSL_LIBRARIES line and you should be ok.

0 Kudos
Reply