Hi Robert,

I must admit I used a pretty simplistic method.  While running my app I run
"top" in another window and look at the process' virtual memory size.

When running without the merge the virtual memory size never changes.  When
running with the merge, the size steadily increases.  After about 16,000
merges my malloc's fail and the process crashes.

I too looked at the merge code and didn't see anything obvious.

I have the feeling that I'm doing something fundamentally wrong that will be
embarrassingly obvious in hindsight, but for now has me stumped.  I'm waiting
for the "Ah ha" moment to strike.

If you can suggest any tests to run, or have any other suggestions, it would
be appreciated.

Thanks,

John

On Thu, 4 Jun 2009, Robert Osfield wrote:

Hi John,

Since StateSet uses ref_ptr<> internally for all StateAttribute, and
merge doesn't create anything on the heap - it just copies then it's
pretty unlikely there is a memory leak.

Far more likely is that the tool you are using for tracking memory
leaks is faulty.  Could you please explain what makes you think you
have a memory leak?

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to