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

basic_dp_complex_dft_2d.c has memory leaks

wujp1978
초급자
947 조회수
First I created a MFC Dialog project, then add "basic_dp_complex_dft_2d.c" to this project, and change "int main(void)" to "int fft_mkl(void)", then call fft_mkl in the MFC App. When the program exited, memory leaks were detected.

Some details is like
"
The thread 'Win32 Thread' (0x1648) has exited with code 2 (0x2).
First-chance exception at 0x7c812afb in testmkl_MFC.exe: 0xA1A01DB2: 0xa1a01db2.
Detected memory leaks!
Dumping objects ->
{209} normal block at 0x003BEB18, 512 bytes long.
Data: < > CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD CD
{208} normal block at 0x02883788, 104 bytes long.
Data: < ; > 18 EB 3B 00 00 00 00 00 00 00 00 00 00 00 00 00
Object dump complete.
The program '[3496] testmkl_MFC.exe: Native' has exited with code 2 (0x2).
"
When I added"basic_dp_complex_dft_2d.c" to a console program, and memory leaks were not found.

My MKL version is 10.3.6.
0 포인트
1 솔루션
Gennady_F_Intel
중재자
947 조회수
Please try to explicitly free the memory allocated by MKL memory managements by calling
mkl_free_buffersfunction at the end of your program.

원본 게시물의 솔루션 보기

0 포인트
2 응답
mecej4
명예로운 기여자 III
947 조회수
It is possible that this is a false warning or that the memory leak is of a benign nature. I say this because I have seen similar false alarms from Valgrind and other memory leak detection programs, which often rely upon looking for certain code sequences to detect memory leaks. For example, one such memory leak checker "finds" memory leaks in any program that does Fortran I/O.
0 포인트
Gennady_F_Intel
중재자
948 조회수
Please try to explicitly free the memory allocated by MKL memory managements by calling
mkl_free_buffersfunction at the end of your program.
0 포인트
응답