Intel® oneAPI Math Kernel Library
Ask questions and share information with other developers who use Intel® Math Kernel Library.

parallel FFT

konglphysics_rutgers
554 Views

Hi,

I am calling cluster FFT/em64 on an opterron/x86-64 machine. Running the program I got error:

Could not convert index 1275070475 into a pointer
The index may be an incorrect argument.
Possible sources of this problem are a missing "include 'mpif.h'" ....

I googled the problem and it seems to be related to 32/64bit. I used the intel mpich-1.2.6/mpif90 compiler.

So how do I check that my code is built as 64bit instead of 32bit?

Also, I have narrowed the problem to subroutine DftiCommitDescriptorDM. The program runs fine If I comment

this subroutine out. Can anyone with experiences of MKL cluster FFT tell me if I can trust that results?

Appreciate your help!!

Lingzhu

0 Kudos
5 Replies
Vladimir_Petrov__Int
New Contributor III
554 Views
Hi Lingzhu,
In general the program should not run finewithout having committed the descriptor. Itlooks like you are not checkingthe status returned by DftiCompute*DM.
To get rid of the error please make sure you are using correct interface libraries and compiler option for 64-bits, i.e. the library namesare ending with _ilp64 and you pass the "-i8" compiler option to the compiler.
In case this does not solve your problem please provide more information on the sequence in which you are calling the Cluster FFT routines.
Best regards,
Vladimir
0 Kudos
konglphysics_rutgers
554 Views

Hi Vladimir,

Thank you very much for your help. I tried your suggestions of calling _ilp together with -i8 flag. I got both good news and bad news.
The god news is the error of "could not convert index to pointer" is gone. The bad news is it failed during CreateDescriptor with
error message "DFTI_1D_LENGTH_EXCEEDS_INT32" while my array is only 45*45*45.

My original linking is as follows. It correctly distributed the third dimension of the array into two processors,
one got 23 points and the other 22. but it failed during commitdescriptor

-L/opt/intel/mkl/10.0.2.018/lib/em64t
-Wl,--start-group /opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_cdft_core.a
/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_intel_lp64.a
/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_intel_thread.a
opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_core.a -Wl,--end-group
/opt/intel/mkl/10.0.2.018/lib/em64t/libguide.a
/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_blacs_intelmpi20_ilp64.a -lpthread

The new sequence is
-i8
-L/opt/intel/mkl/10.0.2.018/lib/em64t
-Wl,--start-group /opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_cdft_core.a
/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_intel_ilp64.a
/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_intel_thread.a
/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_core.a -Wl,--end-group
/opt/intel/mkl/10.0.2.018/lib/em64t/libguide.a
/opt/intel/mkl/10.0.2.018/lib/em64t/libmkl_blacs_intelmpi_ilp64.a -lpthread

it did not allocate any points into any processors.

Any other suggestions? Thanks!

Kind regards,
Lingzhu



Hi Lingzhu,
In general the program should not run fine without having committed the descriptor. It looks like you are not checking the status returned by DftiCompute*DM.
To get rid of the error please make sure you are using correct interface libraries and compiler option for 64-bits, i.e. the library names are ending with _ilp64 and you pass the "-i8" compiler option to the compiler.
In case this does not solve your problem please provide more information on the sequence in which you are calling the Cluster FFT routines.
Best regards,
Vladimir

0 Kudos
konglphysics_rutgers
554 Views

Hi,

I also tried to compile directly the files in the directory of /mkl/10.0.2.018/examples/cdftf by

mpif90 dm_complex_2d_double_ex1.f90 cdft_example_support.f90 -lmkl_cdft_core -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -lguide -lmkl_blacs_intelmpi20_ilp64 -lpthread

and got warining : ifort: Command line warning: no action performed for specified file(s).

Running the program I got the same error of "could not convert index 1000XXXXX into pointer".

Using _ilp wiht -i8 or using stattic linking got the same error. Any ideas what went wrong?

Thanks a lot!

Lingzhu

0 Kudos
Vladimir_Petrov__Int
New Contributor III
554 Views

Hi,

I also tried to compile directly the files in the directory of /mkl/10.0.2.018/examples/cdftf by

mpif90 dm_complex_2d_double_ex1.f90 cdft_example_support.f90 -lmkl_cdft_core -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -lguide -lmkl_blacs_intelmpi20_ilp64 -lpthread

and got warining : ifort: Command line warning: no action performed for specified file(s).

Running the program I got the same error of "could not convert index 1000XXXXX into pointer".

Using _ilp wiht -i8 or using stattic linking got the same error. Any ideas what went wrong?

Thanks a lot!

Lingzhu

Lingzhu,

One thing I definetly overlooked in your post is that you are not using correct BLACS library. This is from our User's Guide: "libmkl_blacs_ilp64.a ILP64 version of BLACS routines supporting the following MPICH versions...". So please try to compile the example with this command line:

mpif90 dm_complex_2d_double_ex1.f90 cdft_example_support.f90 -lmkl_cdft_core -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -lguide -lmkl_blacs_lp64 -lpthread

Best regards,

-Vladimir

0 Kudos
konglphysics_rutgers
554 Views
Vladimir,

Thank you very much for the solution! It worked for compiling and running the MKL example files.
As to my code, I took a different path after struggling linking against MKL cluster FFT for a week.
In my code, I need to do FFT N times. so I now parallelize over N and let each processor do part of it,
The prblem is N is rarely larger than 20 and the limitation is obvious.
Thanks again for your help!

Best wishes,
Lingzhu


Lingzhu,

One thing I definetly overlooked in your post is that you are not using correct BLACS library. This is from our User's Guide: "libmkl_blacs_ilp64.a ILP64 version of BLACS routines supporting the following MPICH versions...". So please try to compile the example with this command line:

mpif90 dm_complex_2d_double_ex1.f90 cdft_example_support.f90 -lmkl_cdft_core -lmkl_intel_lp64 -lmkl_intel_thread -lmkl_core -lguide -lmkl_blacs_lp64 -lpthread

Best regards,

-Vladimir

0 Kudos
Reply