getting started with VML

getting started with VML

Hi,

I just downloaded mkl 8.0.019 and I tried to create a simple program that would calculate tanh of a random matrix:

PROGRAM main
REAL, ALLOCATABLE, DIMENSION(:) :: a, b
INTEGER :: s

s=10000

ALLOCATE(a(s))
ALLOCATE(b(s))

a = 0
b = 0

CALL RANDOM_NUMBER(a)
CALL VDATANH( s, a, b)
END PROGRAM

/opt/intel/fc/9.0/bin/ifort -w90 -w95 -o nn -Vaxlib -static-libcxa -L/opt/intel/mkl/8.0/lib/32 -lmkl_blas95 -lmkl_lapack -lvml -lmkl_ia32 -lguide -lpthread -I/opt/intel/mkl/8.0/include/ tantest.f90

I get all sorts of fatal errors depending on what tweaks I make to the code. The particular one for the code shown is:

*** glibc detected *** free(): invalid next size (normal): 0x080ab350 ***
forrtl: error (76): IOT trap signal

Does anybody know what I am doing wrong?

Thanks
Joan

3 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

1) You forgot to include mkl_vml.fi header file into your program
2) For vd (double precision accuracy) functions REAL type should have lenght 8 (REAL*8)

If you correct these two mistakes your code will work fine! :-)

Thanks for the answer. It was the double precision thing that was getting me.

Joan

Login to leave a comment.