← Back to team overview

compiz team mailing list archive

[Bug 758248] Re: memory leaking in compiz

 

I have tested my suggestion - removing the "if (!OwnsTheReference() )"
blocks from Object::Reference and Object::UnReference.

The good news:
* Unity is stable with the change.
* The corruption described in bug 769957 and seemingly due to window/nux leaks is half fixed (but not fully)

The bad news:
* compiz average memory usage seems to be LARGER, not smaller.

So it seems on average, fixing the reference count to be larger when it
should be larger actually means that broken client code (unity) which is
missing the required number of Dispose/UnReference calls now leaks in
places it didn't before. This makes sense if you imagine that floating
references assigned to container objects are more common than non-
contained floating references.

So sadly not a change I can recommend right now.

A more defensive and more compatible fix involves fixing the floating
references (mostly in unity?) one-by-one :(

I strongly suggest separating each type of leak into a separate bug,
where the code changes and valgrind results are small and individually
verifiable. The Load2DTextureFile leak is one such example. That can be
a bug in itself.

It's probably not realistic to continue trying to fix everything in this
one bug and then say "the leaks in compiz are now all fixed".

-- 
You received this bug notification because you are a member of compiz
packagers, which is subscribed to compiz in Ubuntu.
https://bugs.launchpad.net/bugs/758248

Title:
  memory leaking in compiz


References