Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29275 Discussions

Handle/memory leak in "system()"?

xgli
Beginner
504 Views
The issue is under the following build "Intel Fortran Compiler Integration for Microsoft Visual Studio .NET 2003, Version 9.0.3157.2003, Copyright (C) 2002-2006 Intel Corporation"

Symptom: "system()" does not release handles and related resources. It can be seen from task manager or any other process monitors.
Tested using the following code:
-------------------------------------------
program sysintel

use ifport

implicit none

integer i, iret

do i = 1, 10000
iret=system('echo 1 > dump')
end do

end program sysintel
-------------------------------------------

As the iteration goes on, the system resource gets exhausted. Same codes written in C or Fortran using dfport are all working properly. Is this a bug in IVF?
0 Kudos
2 Replies
Steven_L_Intel1
Employee
504 Views
Not that I am aware of. I'd be astonished if system had this problem and systemqq did not. Please file a support request with Intel Premier Support and we'll look into it.
0 Kudos
jimdempseyatthecove
Honored Contributor III
504 Views

Xgli,

I have seen a similar problem with my application which uses the Array Visualizer to displaycomplicated3D graphs of a simulation as the simulation runs. The Array Visualizer has a library that links into the applicaton but the instanciation of the Display driver isrun as a seperate application. The AV library launches the AV Display driver once then communicates with the AD driver somehow (looks like shared memory).

As my application runs, I see what looks like a slow memory leak.

I do not know if this is a Windows problem or something to do with what is called via the AV library.

As far as I can determine on my side the leak occures in the AV Display driver. Because I can delete the instance of the AD Display driver while my application runs, the system reclaims the memory, then I can click on a button on my app to instruct it to open a new display window. This can be done while the simulation continues to run.

Jim Dempsey

0 Kudos
Reply