[Goodies-dev] [Bug 15218] Plugin with 3 instances displaying min, ave, max frequency all grow memory usage from initial <20MB.

bugzilla-daemon at xfce.org bugzilla-daemon at xfce.org
Wed May 1 00:59:16 CEST 2019


https://bugzilla.xfce.org/show_bug.cgi?id=15218

--- Comment #2 from Andreas Müller <schnitzeltony at gmail.com> ---
Yes this bugs me either: on RaspberryPi running 24/7 sessions need restart
after few days due to this.

Did some valgrinding (as suggested in
https://docs.xfce.org/xfce/xfce4-panel/debugging) with interesting results:

1. I started some valgrind-panel-sessions with default settings of
cpufreq-plugin: With Icon / default Font size -> Font was far too big to
display all contents. During active valgrind session there are pairs of lines
dropped periodically as

| x nodes, y survivors (z%)
| x new table size (stepup)

I watched them passing by and did not see monotonic increase of numbers. They
increased but I expected more.

2. Then I modified cpufreq-plugin settings to similar as they are on my Raspi:
No Icon / reduce font size so that texts fit into plugin's area without being
clipped (in my case Sans 9). Now the increase turned straighter (see file 8468
above - search for 'new table size').

3. Continued with this and that an then stopped xfce-panel. This causes
valgrind to create the final bill (scroll to end of file). The main memory leak
(last in file I skipped the others to reduce size - was 7.3MB): is in
cpufreq_update_plugin -> cpufreq_label_set_font ->
gtk_css_provider_load_from_data

Questions (am not a GTK expert) which can lead to a fix
1. Is there some cleanup for parameters in gtk_css_provider_load_from_data
required?
2. This might just reduce leak but: Is it necessary to call
cpufreq_label_set_font on each cpufreq_update_plugin? The font size is fixed by
configuration

Hope this helps

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the Goodies-dev mailing list