closeWithActiveWindows segfault with softpipe on arm64 and mips
It works well with llvmpipe.
I find this problem on Debian experimental. Then env includes:
Mesa: 23.1.5/23.1.4 Mutter: 44.3 Gnome-Shell: 44.3 GJS: 1.76.2 MozJS: 102.14.0
How to reproduce:
- Get an arm64 machine.
- create Debian Sid bootstrap
debootstrap sid sid http://deb.debian.org/debian systemd-nspawn -D sid cd /root echo "deb http://deb.debian.org/debian experimental main" >> /etc/apt/sources.list echo "deb-src http://deb.debian.org/debian sid main" >> /etc/apt/sources.list echo "deb-src http://deb.debian.org/debian experimental main" >> /etc/apt/sources.list echo "deb http://deb.debian.org/debian-debug sid-debug main" >> /etc/apt/sources.list echo "deb http://deb.debian.org/experimental-debug experimental-debug main" >> /etc/apt/sources.list
apt install libgjs0g-dbgsym
apt build-dep --arch-only gnome-shell -t experimental
apt source gnome-shell -t experimental
cd gnome-shell-44*
dpkg-buildpackage -B # built without error, since llvmpipe is used
- Let's try softpipe:
GALLIUM_DRIVER=softpipe LIBGL_ALWAYS_SOFTWARE=true XDG_RUNTIME_DIR=/tmp/ G_MESSAGES_DEBUG='GNOME Shell' GNOME_SHELL_BUILDDIR=/root/gnome-shell/gnome-shell-44.3/obj-aarch64-linux-gnu/src GNOME_SHELL_DATADIR=/root/gnome-shell/gnome-shell-44.3/obj-aarch64-linux-gnu/data LD_LIBRARY_PATH=/root/gnome-shell/gnome-shell-44.3/obj-aarch64-linux-gnu/subprojects/gvc G_DEBUG=fatal-criticals GSETTINGS_BACKEND=memory GI_TYPELIB_PATH=/root/gnome-shell/gnome-shell-44.3/obj-aarch64-linux-gnu/subprojects/gvc GNOME_SHELL_SESSION_MODE=user MALLOC_PERTURB_=126 GSETTINGS_SCHEMA_DIR=/root/gnome-shell/gnome-shell-44.3/obj-aarch64-linux-gnu/data SHELL_BACKGROUND_IMAGE='[<File: tests/data/background.png (not built)>]' /root/gnome-shell/gnome-shell-44.3/obj-aarch64-linux-gnu/tests/gnome-shell-dbus-runner.py /root/gnome-shell/gnome-shell-44.3/obj-aarch64-linux-gnu/src/gnome-shell-perf-tool --headless --perf=closeWithActiveWindows
- use gdb:
# add a new line after line 43 : args = [] wrap = "gdb --args" #note the space, as required by python.
- Rerun the cmd of step 8. It still fails.
- in the gdb cmd:
info address shell_wm_completed_map # Get the address of `shell_wm_completed_map` function from `gnome-shell/src/shell-wm.c`.
- in the gdb cmd:
b function.cpp:1050 if m_invoker.native_address==0xfffff7d33560 # replace the address with the one you just got.
- in the gdb cmd:
continue
- you won't get the failure.
- in the gdb cmd:
d # delete all breakpoints r # rerun # the segfault comes back.
And FYI: on amd64, this problem never appears. on mips64el, this problem always appears even with gdb's breakpoint. I guess it is due to some problem of multithread.