Hello everyone!

I configure HDF5 build with command:

cmake -G "Visual Studio 12" -DBUILD_SHARED_LIBS=ON -DCMAKE_BUILD_TYPE=Release -DHDF5_ENABLE_Z_LIB_SUPPORT=ON -DHDF5_ALLOW_EXTERNAL_SUPPORT=SVN -DZLIB_SVN_URL=http://svn.hdfgroup.uiuc.edu/zlib/trunk -DHDF5_ENABLE_THREADSAFE=ON hdf5-1.8.14

Then I compile and run the following minimal (Delphi) program, which emulates multiple hdf5.dll dynamic load-use-unload pattern:

program test;

uses
  windows;

type
  herr_t = Integer;
var
  Dll: HMODULE;
  H5open: function: herr_t; cdecl;
  H5close: function: herr_t; cdecl;
begin
  while True do
  begin
    Dll := LoadLibrary('hdf5.dll');
    try
      @H5open := GetProcAddress(Dll, 'H5open');
      @H5close := GetProcAddress(Dll, 'H5close');
      H5open();
      H5close();
    finally
      FreeLibrary(Dll);
    end;
  end;
end.

When I run the above program for some time, I see memory usage constantly growing (~1MB per minute).

The problem is reproducible with HDF5 1.8.13, but not reproducible when I configure with -DHDF5_ENABLE_THREADSAFE=OFF or use stock HDF5 binaries.

Albeit my minimal program is pathological, it illustrates real-life usage pattern (imagine long-running server application). Also, the presence of even minimal memory leaks in HDF5 complicates memory leak profiling for the whole application.

Is it a known problem?
Is there additional info I should provide for you to help localize and eliminate the problem?

Best wishes,
Andrey Paramonov

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.


_______________________________________________
Hdf-forum is for HDF software users discussion.
[email protected]
http://mail.lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org
Twitter: https://twitter.com/hdf5

Reply via email to