flightlessmango / MangoHud

A Vulkan and OpenGL overlay for monitoring FPS, temperatures, CPU/GPU load and more. Discord: https://discordapp.com/invite/Gj5YmBb
MIT License
6.11k stars 263 forks source link

Segfaults in emulators after 0.7.2 #1338

Open italoghost opened 1 month ago

italoghost commented 1 month ago

Describe the bug After updating to 0.7.2, some emulators are having segfaults. For example, suyu and cemu segfaults when you try to load a game. RPCS3 appimage segfaults when opening the program.

Logs:

~$ mangohud '/home/ghost/AppImages/rpcs3.appimage'
Found AppImage path: /home/ghost/AppImages/rpcs3.appimage
Debugger: 0
RPCS3: SYS: RPCS3 v0.0.32-16541-a3457c29 Alpha | HEAD
RPCS3: SYS: AMD Ryzen 7 5700X3D 8-Core Processor | 16 Threads | 15.54 GiB RAM | TSC: 3.000GHz | AVX+ | FMA3
RPCS3: SYS: Operating system: POSIX, Name: Linux, Release: 6.6.32-1-lts, Version: #1 SMP PREEMPT_DYNAMIC Sat, 25 May 2024 20:20:51 +0000
RPCS3: SYS: Current Time: 2024-05-28T11:09:50
qt.qpa.wayland: No shell integration named "xdg-shell" found
qt.qpa.wayland: No shell integration named "wl-shell" found
qt.qpa.wayland: No shell integration named "ivi-shell" found
qt.qpa.wayland: No shell integration named "qt-shell" found
qt.qpa.wayland: Loading shell integration failed.
qt.qpa.wayland: Attempted to load the following shells QList("xdg-shell", "wl-shell", "ivi-shell", "qt-shell")
qt.qpa.plugin: Could not load the Qt platform plugin "wayland" in "" even though it was found.
RPCS3: SYS: 
Segfault reading location 00000000be782f0c at 00007650c86f426e.
Thread: Main Thread.

RPCS3: SIG: Thread terminated due to fatal error: Segfault reading location 00000000be782f0c at 00007650c86f426e.
Thread: Main Thread.

RPCS3: Segfault reading location 00000000be782f0c at 00007650c86f426e.
Thread: Main Thread.

Emulation is stopped
Build: "0.0.32-16541-a3457c29 Alpha | HEAD"
Date: "2024-05-28T11:09:50"
Found AppImage path: /home/ghost/AppImages/rpcs3.appimage
Debugger: 0
qt.qpa.wayland: No shell integration named "xdg-shell" found
qt.qpa.wayland: No shell integration named "wl-shell" found
qt.qpa.wayland: No shell integration named "ivi-shell" found
qt.qpa.wayland: No shell integration named "qt-shell" found
qt.qpa.wayland: Loading shell integration failed.
qt.qpa.wayland: Attempted to load the following shells QList("xdg-shell", "wl-shell", "ivi-shell", "qt-shell")
qt.qpa.plugin: Could not load the Qt platform plugin "wayland" in "" even though it was found.
Abortado (imagem do núcleo gravada)
~$ mangohud suyu
Unhandled SIGSEGV at rip 0x000070933e4dc9d4
~$ mangohud cemu
Falha de segmentação!
Error: signal 11:
/usr/lib/libwayland-client.so.0(wl_proxy_get_version+0x4) [0x73eb665989d4]+0x4) [0x73eb665989d4]
/usr/lib/libc.so.6(+0x3cae0) [0x73eb65eabae0]
/usr/lib/libwayland-client.so.0(wl_proxy_get_version+0x4) [0x73eb665989d4]+0x4) [0x73eb665989d4]
/usr/lib/libvulkan_radeon.so(+0x17e3ac) [0x73ea1ad7e3ac]
/usr/lib/libvulkan_radeon.so(+0x173544) [0x73ea1ad73544]
/usr/lib/libvulkan.so(+0x3d585) [0x73eb5c46f585]
/usr/lib/mangohud/libMangoHud.so(+0x2b061) [0x73ea1a82b061]
cemu(+0x867650) [0x5dac7c971650]
cemu(+0x532dbc) [0x5dac7c63cdbc]
cemu(+0x957e1c) [0x5dac7ca61e1c]
cemu(+0x9213a5) [0x5dac7ca2b3a5]
cemu(+0x9201ac) [0x5dac7ca2a1ac]
cemu(+0x91e972) [0x5dac7ca28972]
cemu(+0xd769c6) [0x5dac7ce809c6]
cemu(+0xd76dae) [0x5dac7ce80dae]
cemu(+0xd76f04) [0x5dac7ce80f04]
cemu(+0xd76faf) [0x5dac7ce80faf]
cemu(+0xd77059) [0x5dac7ce81059]
cemu(+0xd76863) [0x5dac7ce80863]
cemu(+0xcb4d0a) [0x5dac7cdbed0a]
cemu(+0xf4d88e) [0x5dac7d05788e]
cemu(+0xf4d957) [0x5dac7d057957]
/usr/lib/libglib-2.0.so.0(+0x5ca89) [0x73eb64f65a89]
/usr/lib/libglib-2.0.so.0(+0xbe9b7) [0x73eb64fc79b7]
/usr/lib/libglib-2.0.so.0(g_main_loop_run+0x137) [0x73eb64f66787]+0x137) [0x73eb64f66787]
/usr/lib/libgtk-3.so.0(gtk_main+0x8f) [0x73eb657e390f]+0x8f) [0x73eb657e390f]
cemu(+0xf5f165) [0x5dac7d069165]
cemu(+0xce2ca1) [0x5dac7cdecca1]
cemu(+0xcb575a) [0x5dac7cdbf75a]
cemu(+0xd16af7) [0x5dac7ce20af7]
cemu(+0x40b5fa) [0x5dac7c5155fa]
/usr/lib/libc.so.6(+0x25c88) [0x73eb65e94c88]
/usr/lib/libc.so.6(__libc_start_main+0x8c) [0x73eb65e94d4c]+0x8c) [0x73eb65e94d4c]
cemu(+0x408db5) [0x5dac7c512db5]

Stacktrace and additional info written to:
/home/ghost/.local/share/Cemu/log.txt

List relevant hardware/software information

To Reproduce Steps to reproduce the behavior: Try to launch a game within the emulator (suyu or cemu) or try to launch the emulator itself (RPCS3) when adding the mangohud environment variable.

Expected behavior Do not segfault.

Screenshots N/A.

Additional context N/A.

italoghost commented 1 month ago

Additional information: I am using GNOME Wayland and both suyu and cemu are running natively, while RPCS3 is running through XWayland.

the-science-guy commented 1 month ago

For me it segfaults in suyu when closing / stopping emulation instead of when loading a game

mangohud suyu
qt.gui.imageio: libpng warning: iCCP: known incorrect sRGB profile
Unhandled SIGSEGV at rip 0x00007c888c4801d0
[1]    12989 segmentation fault (core dumped)  mangohud suyu

Running X11 with cinnamon on Arch

Etaash-mathamsetty commented 1 month ago

rpcs3: some issue with the app image (it's probably loading libraries from the wrong places or something) suyu: can't test, I don't have any nintendo games

Etaash-mathamsetty commented 3 weeks ago

easy solution would be to statically link libxkbcommon but that would require adding another subproject; ill try it later