Comment 1 for bug 400849

Revision history for this message
Samuel Buffet (samuel-buffet) wrote :

After some tests, I came to the conclusion that this memory issue is caused by screens.

Indeed, it looks like screen objects are never destroyed by the garbage collector. So all their content is not released from memory. This bug is more visible on screens that include clutter textures cause those are huge memory consumers.

To fix that, I see to solutions :

i/ we find why the garbage collector does not destroy them = we find where the python interpreter still keep a reference
ii/ we don't destroy them but keep a visible/accessible reference to them in order to avoid to recreate them in case we need one of them later on. Note, this solution is not good if we want to minimize the memory footprint of Entertainer.

Quick estimation (assuming that all the memory goes in Textures):

Test on my machine gives 130Mb for a screen containing 266 media. So around 0.5Mb per media texture.

So someone with 100 vids and 100 albums => 100Mb
So someone with 50 vids and 200 albums => 125Mb

Entertainer out of the box on the Main screen => around 37Mb

The backend itself 240Mb (what the hell is that??)