pop-os / gnome-shell

Pop!_OS fork of https://git.launchpad.net/~ubuntu-desktop/ubuntu/+source/gnome-shell
GNU General Public License v2.0
25 stars 4 forks source link

Memory leak gnome-shell #92

Open Guyv-dev opened 2 years ago

Guyv-dev commented 2 years ago

Distribution (run cat /etc/os-release): NAME="Pop!_OS" VERSION="21.10" ID=pop ID_LIKE="ubuntu debian" PRETTY_NAME="Pop!_OS 21.10" VERSION_ID="21.10" HOME_URL="https://pop.system76.com" SUPPORT_URL="https://support.system76.com" BUG_REPORT_URL="https://github.com/pop-os/pop/issues" PRIVACY_POLICY_URL="https://system76.com/privacy" VERSION_CODENAME=impish UBUNTU_CODENAME=impish LOGO=distributor-logo-pop-os

Issue/Bug Description:

I experience extensive ram usage from gnome-shell (GNOME Shell 40.5). I used heap track without any user extension enabled - logs attached. The only extension that was left enabled (Cosmic Dock - DISABLED):

  1. Cosmic Workspaces
  2. Pop COSMIC
  3. Pop Shell
  4. Ubuntu Appindicators

2.4GB usage: leak2 leak


5.7GB usage:

leak57 leak571 leak572

mmstick commented 2 years ago

You'd have to build the gnome-shell package from source and install the dbgsym package to get the debug symbols that are missing.

git clone https://github.com/pop-os/gnome-shell
cd gnome-shell
git checkout master_impish
sudo apt build-dep gnome-shell
dpkg-buildpackage -b
sudo dpkg -i ../*gnome-shell*deb

But with 22.04 so close and that will be shipping with GNOME 42, there's a chance that the issue may be fixed in GNOME 42 already.

Guyv-dev commented 2 years ago

I am still facing a memory leak (I upgraded to pop_os 22.04 with gnome 42). I tried to build gnome-shell just like you suggested, and I am getting an error when I run dpkg-buildpackage -b:

dpkg-checkbuilddeps: error: Unmet build dependencies: libgnome-bluetooth-dev (>= 3.9.0) libmutter-8-dev (>= 40.0)
dpkg-buildpackage: warning: build dependencies/conflicts unsatisfied; aborting
dpkg-buildpackage: warning: (Use -d flag to override.)
mmstick commented 2 years ago

sudo apt build-dep gnome-shell will install all development dependencies of gnome-shell.

Guyv-dev commented 2 years ago

if I am not wrong, master_impish is gnome 40 (I am now on pop 22.04 with 42), so maybe it could explain why sudo apt build-dep gnome-shell doesn't install these dependencies (libmutter-8-dev - doesn't have release for 22.04).

i tried once again with master branch, now i get:

 signfile gnome-shell_42.0-2ubuntu2pop1_amd64.buildinfo
gpg: skipped "Michael Aaron Murphy <mmstick@pm.me>": No secret key
gpg: dpkg-sign.gQ9PR1Ct/gnome-shell_42.0-2ubuntu2pop1_amd64.buildinfo: clear-sign failed: No secret key
mmstick commented 2 years ago

GNOME 42 on 21.10 wouldn't be a supported configuration. Try 22.04

Guyv-dev commented 2 years ago

I installed the built gnome, now what should i do? run valgrind / heaptrack ?

Guyv-dev commented 2 years ago

Screenshot from 2022-06-12 16-24-44 Screenshot from 2022-06-12 16-24-31 Screenshot from 2022-06-12 16-24-00

Guyv-dev commented 2 years ago

Are the screenshots help to identify the problem?