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

differences between mkl fft ia32 and intel64

Saidani__Tarik
Beginner
659 Views

Hi,

I am experiencing major differences in the output of the MKL fft DftiComputeForward routine between 32-bit (ia32) and 64-bit (intel64) versions. Do you see any obvious reason for this (different code, intermediate precision and so on ...). If there is any way to make it consistent between 32 and 64-bit could you please tell me how can I achieve this.

Many thanks

Tarik

0 Kudos
2 Replies
Dmitry_B_Intel
Employee
659 Views
Hi Tarik, To add performance, the intel64 implementation goes through code paths very different from the ia32 ones, so some difference in results is possible and may be not easy to eliminate. It should not be major, though! It would greatly help us if you shared a bit more detail about precise FFT problem that you observe the difference with. For consistency, it is good to make sure that the data is aligned at some good boundary (e.g. 64 bytes) in both case - function MKL_malloc should help with this. If the transform computed is large enough, so that the computation is parallelized, then you may try to limit number of threads to just one (by setting environment variable OMP_NUM_THREADS=1). Thanks Dima
0 Kudos
Saidani__Tarik
Beginner
659 Views
Hi Dima, Thank you for answering my question. I can give you some more details on the differences I have. First of all, I do not think that it could be a threading (parallel reduction) problem as I am using mkl sequential version. I have tried the mkl_allocate with a 64 byte alignment as you recommended but it did not help that much. I tried both single and double precision FFT and differences are still there. My first concern is that the relative differences can reach 50% between two samples ((abs(diff)/value)*100). The only problem I could see is that the dynamic range of my values is quite high (please see attached ascii file). Do you have any opinion on this. Many thanks Tarik
0 Kudos
Reply