Problem 191

Summary: Possible memory leak
Product: Examples/Basic and Novice Reporter: delgadom
Component: N02Assignee: Gabriele Cosmo <Gabriele.Cosmo>
Status: RESOLVED INVALID    
Severity: normal    
Priority: P2    
Version: 2.0   
Hardware: PC   
OS: Linux   

Description delgadom 2001-01-15 09:11:31 CET
The N02 example doesn't free a small chunk of memory when the simulation of one
event has finished. This results in a large consumption when the number of
events is large enough.
Comment 1 John Apostolakis 2001-01-16 09:42:59 CET
*** Bug 192 has been marked as a duplicate of this bug. ***
*** 'John.Apostolakis@cern.ch' will be responsible for bug 192. ***
Comment 2 Gabriele Cosmo 2001-01-18 10:47:59 CET
The apparent leakage is due to the generation and therefore "storage"
in memory of hits: once an event which eventually generates huge number
of hits happens, the wasted memory size increases.
The chance of having such an event increases with the number
of events. Memory allocated is however correctly deleted.
For example: an application executing two 100 events runs with
the same random number will waste the same amount of memory of
an application executing only one of such runs.
To be noticed moreover that a bug discovered in G4Allocator (see
report #181) has been recently fixed and will be available in a
future patch or minor release.