Problem 1324 - Memory leak when using the "new" command /grdm/setRadioactiveDecayFile
Summary: Memory leak when using the "new" command /grdm/setRadioactiveDecayFile
Status: REOPENED FIXED
Alias: None
Product: Geant4
Classification: Unclassified
Component: processes/hadronic/models/radioactive_decay (show other problems)
Version: 9.5
Hardware: Apple Mac OS X
: P5 critical
Assignee: desorgher
URL:
Depends on:
Blocks:
 
Reported: 2012-06-14 13:54 CEST by stuff
Modified: 2012-09-11 12:01 CEST (History)
1 user (show)

See Also:


Attachments
patch to fix bug (3.79 KB, application/octet-stream)
2012-06-14 13:54 CEST, stuff
Details
screen dump for massif heap profiler (199.21 KB, image/png)
2012-09-11 11:59 CEST, stuff
Details

Note You need to log in before you can comment on or make changes to this problem.
Description stuff 2012-06-14 13:54:05 CEST
Created attachment 174 [details]
patch to fix bug

Hi,

I have a simulation where I create a lot of radioactive nuclei and these decay. If I set my own decay file I noticed that the programmed filled my disk by "swapping". This did however not slow down the program, this because the created leaked object was never used again... Difficult to find since the actually used memory of the code remains the same on any system with swap (i.e all). However, I think I found the problem, and I include  a patch. When using a user set decay file the code did not keep track of the fact that it had already loaded decay data to it was done every time I created an ion.


cheers


Joa
Comment 1 desorgher 2012-07-10 17:48:41 CEST
Dear Joa,

Many thanks for the  bug report!
Indeed for the cases of user defined radioactive decay file., 
the nuceli were re-loaded indefinitively.
Some of the solutions that you proposed   was already brought to the code for 
solving a problem with the life time of the user defined radioactive decay file.  But for what concern the stop  of reloading of the same file, I did correct the code following your suggestions.

Best regards


Laurent
Comment 2 stuff 2012-09-11 11:59:37 CEST
Created attachment 186 [details]
screen dump for massif heap profiler
Comment 3 stuff 2012-09-11 12:01:24 CEST
Hi all,

it seems as if this bug has resurfaced with geant4.9.6.b01. See included screen dump with massif heap profiler


I presently do not have the time to fix this.

cheers


Joa