Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
Comunicados
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.

memory leaks using "heap_arrays"

dlemmon1
Principiante
880 Visualizações
The new "heap_arrays" option is great. But I'm noticing some occasional memory leaks which are quite serious. For instance, within a "where" block the program's memory usage suddenly begins to spike until it hits 4GB. The same thing happens while passing an array subset (using an array of indices) to a subroutine. These problems only occur when I build using the "heap_arrays" option.

My application is a DLL being called by a larger program (SAS). Unfortunately I haven't been able to reproduce the problems with example code, even when I'm calling the exact subroutine where the trouble occurs. Not sure why -- maybe I need to put my test case inside a DLL (need some time to do this...). Until I can do this, I'm not sure if I should go to the trouble of submitting a bug report. Anyway, I'm curious to see if anyone else has been seeing similar things with heap_arrays.
0 Kudos
3 Respostas
jimdempseyatthecove
Colaborador honorário III
880 Visualizações
If you are using the Page File information from Task Manager then the information you see is the amount of virtualmemory your program walked on. It is not the amount of memory for program + allocations.
dlemmon1
Principiante
880 Visualizações
Thanks for the help. I'll be more clear. I am looking at the column "Memory (Private Working Set)" for the host process (sas.exe) in Task Manager under "Processes". In the debugger it's simply performing a simple "where" block operation for a fairly large array, and the amount of memory starts rapidly increasing by hundreds of megabytes until it runs out of memory. So something strange is happening. Also, in the other scenario I mentioned, I'm passing array subsets to a function (using an indexing array), and each time I call the subroutine, the "Memory (Private Working Set)" for sas.exe increases by several megabytes, but it is not freed up after the function exits. I've tried to reproduce this situation in a simple Fortran program but it doesn't happen...
Steven_L_Intel1
Funcionário
880 Visualizações
You will not see the working set go down when memory is freed. That memory is still in your address space in a pool belonging to the memory allocator.
Responder