3.16.30 SIGSEGV in libVkLayer_steam_fossilize.so / child exits, 3.16.25 OK on NVIDIA + Hyprland
Distro: CachyOS (cat /etc/os-release)
Kernel: uname -r (7.2.8-1-cachyos)
GPU: RTX 4070 SUPER, nvidia-smi -> 615.71.09
Compositor: Hyprland Wayland
Gamescope bad: 3.16.30-1, good: 3.16.25-1 (grep gamescope /var/log/pacman.log)
To reproduce, use this setting in the launch option: gamescope -w 1920 -h 1080 -f -- %command%
Tested on Total War WARHAMMER III, Proton Experimental Elden Ring, Proton Experimental
Logs: Stack trace of thread 24310: PID: 24301 (gamescope-wl) TID: 24326 (gamescope-shdr) UID: 1000 (mihai) GID: 1000 (mihai) Signal: 11 (SEGV) si_code: SEGV_MAPERR Timestamp: Tue 2026-09-29 11:37:15 EDT (16min ago) Command Line: gamescope --backend wayland -w 3440 -h 1440 -W 3440 -H 1440 -r 200 --force-orienta> Executable: /usr/bin/gamescope Control Group: /user.slice/user-1000.slice/[email protected]/session.slice/[email protected]> Unit: [email protected] User Unit: [email protected] Slice: user-1000.slice Owner UID: 1000 (mihai) Boot ID: 08e4ce241ee84199ae19ecc7bab230a2 Machine ID: 2f1fa6da782d4b9ba0d236379ff3b3fb Hostname: bigboss Storage: /var/lib/systemd/coredump/core.gamescope-wl.1000.08e4ce241ee84199ae19ecc7bab230a2.> Size on Disk: 24.4M Message: Process 24301 (gamescope-wl) of user 1000 dumped core.
Stack trace of thread 24326:
#0 0x00007f68433b7fe8 n/a (libc.so.6 + 0x1b7fe8)
#1 0x00007f6823f5572c n/a (libVkLayer_steam_fossilize.so + 0x4572c)
#2 0x00007f6823f73c87 n/a (libVkLayer_steam_fossilize.so + 0x63c87)
#3 0x00007f6823fa39ab n/a (libVkLayer_steam_fossilize.so + 0x939ab)
#4 0x000055ff69692c96 n/a (gamescope + 0x13bc96)
#5 0x000055ff6969382f n/a (gamescope + 0x13c82f)
#6 0x000055ff696a407d n/a (gamescope + 0x14d07d)
#7 0x00007f6843705396 n/a (libstdc++.so.6 + 0x105396)
#8 0x00007f68432acfb1 n/a (libc.so.6 + 0xacfb1)
#9 0x00007f684334c60c n/a (libc.so.6 + 0x14c60c)
Stack trace of thread 24301:
#0 0x00007f68432b61f2 n/a (libc.so.6 + 0xb61f2)
#1 0x00007f68432a95c8 n/a (libc.so.6 + 0xa95c8)
#2 0x00007f68432aeee7 n/a (libc.so.6 + 0xaeee7)
...skipping...
I can reproduce this on NVIDIA with the nested Wayland backend. It looks like the same shutdown-order bug as #2516, and #2542 fixes it in my testing.
Nothing stops m_pipelineThread before exit(); it only gets joined from the destructor of the global g_device. By the time that runs, the Vulkan layer and driver exit handlers have already run, but gamescope-shdr is still precompiling inside vkCreateComputePipelines. With Steam's fossilize layer loaded (Steam enables it for games, and gamescope's own device inherits it), the shader thread ends up in pthread_mutex_lock inside libVkLayer_steam_fossilize.so and gamescope either:
- hangs on exit: both threads in futex waits with no CPU progress over 30 s
- aborts: glibc assert in
__pthread_tpp_change_priority, orstd::system_error: Invalid argument - or exits but logs
NVVM compilation failed: 3/vkCreateComputePipelines failed (VkResult: -13)afterPrimary child shut down!
Without fossilize, master doesn't crash or hang in my runs, but it still logs those driver errors after exit in half of them. So the race is in gamescope, and fossilize is what makes it fatal.
It can only trigger while precompile is still running. That means the child exits within roughly the first 30 s and the pipelines aren't cached yet. Time gamescope-shdr stays alive:
| version | cold driver cache | warm |
|---|---|---|
| 3.16.25 | 21.7 s | <0.5 s |
| 3.16.28 | 22.2 s | <0.5 s |
| 3.16.29 | 31.3 s | <0.5 s |
| master | 32.3 s | <0.5 s |
So the bug predates 3.16.29. 3.16.29 made the window about 40% longer: the precompile set went from 108 to 145 pipelines when k_nMaxLayers went from 6 to 8 (8f212644) and SGSR was added (85438372). Upgrading also invalidates the cached pipelines. Together that probably explains why it looked like a clean 3.16.25 → 3.16.30 regression.
@alpenstorm, did the game itself close or crash in the first ~30 seconds when this happened? If so, that early exit is a separate problem, and this race is what turned it into a gamescope crash.
Cold caches, nested Wayland, fossilize enabled, 20 runs each:
| build | crash | hang on exit | errors after child exit | fully clean |
|---|---|---|---|---|
| 3.16.25 | 1 | 3 | 16 | 0/20 |
| master 0be04e4e | 0 | 15 | 5 | 0/20 |
| master + #2542 | 0 | 0 | 0 | 20/20 |
Reproducer (no Steam or game needed)
export ENABLE_VK_LAYER_VALVE_steam_fossilize_1=1
export STEAM_FOSSILIZE_DUMP_PATH=$(mktemp -d)/cache
export __GL_SHADER_DISK_CACHE=0 # cold driver cache; with a warm cache precompile finishes in <0.5 s
gamescope --backend wayland -w 1280 -h 720 -- sleep 2
RTX 3080 Ti, NVIDIA 620.70.06, KDE Plasma 6 Wayland, kernel 7.3.4, gamescope built from source. I've only tested this emulation of the Steam environment, not an actual Steam launch.
Backtraces
Hang (master 0be04e4e), after sending SIGABRT to the stuck process:
Main thread:
#4 std::thread::join()
#5 std::jthread::join() (gamescope)
#6 __run_exit_handlers (libc.so.6)
#7 exit (libc.so.6)
#8 __libc_start_call_main (libc.so.6)
gamescope-shdr:
#0 __pthread_mutex_lock_full (libc.so.6)
#1 n/a (libVkLayer_steam_fossilize.so + 0xa84e2)
#2 n/a (libVkLayer_steam_fossilize.so + 0xd741c)
#3 CVulkanDevice::compilePipeline(...) (gamescope)
#4 CVulkanDevice::compileAllPipelines(std::stop_token)
Abort (3.16.30), same main-thread stack:
gamescope-shdr:
#4 __libc_assert_fail
#5 __pthread_tpp_change_priority
#6 __pthread_mutex_lock_full
#7 n/a (libVkLayer_steam_fossilize.so + 0xa84e2)
#8 n/a (libVkLayer_steam_fossilize.so + 0xd741c)
#9 CVulkanDevice::compilePipeline(...)
#10 CVulkanDevice::compileAllPipelines(std::stop_token)
Fatal glibc error: tpp.c:83 (__pthread_tpp_change_priority): assertion failed: new_prio == -1 || (new_prio >= fifo_min_prio && new_prio <= fifo_max_prio)
In the latest version of gamescope, this issue does not exist any longer. It was just 3.16.30 that was the issue, now it works fine.
Thanks for following up! Glad it's working for you now. I don't think the underlying bug is fixed yet, though, so it may come back.
The crash needs the game (or a launcher stage) to exit while gamescope is still precompiling its pipelines at startup. That takes ~30 s with a cold NVIDIA shader cache, typically the first launch after a gamescope or driver update, and under 0.5 s once the cache is warm. I can't tell whether that matches when your crash happened, but it would explain both "3.16.25 OK" and "fine now".
I retested 3.17.0 (the current Arch/CachyOS package) with the same reproducer as before (nested Wayland backend, Steam's fossilize layer enabled, child exits after 2 s) on an RTX 3080 Ti / NVIDIA 620.70.06:
- cold cache, 20 runs: 4 crashes, 9 hangs (still running at a 60 s timeout), 7 clean exits with compile errors logged after exit, 0 fully clean
- warm cache, 10 runs: 10/10 clean
As far as I can tell nothing merged since 3.16.30 touches the precompile thread. 3.17.0's shutdown change (aa289ea5) joins the present-wait thread, which is a different thread. #2542 still makes it 20/20 clean with a cold cache.
If you want to check on your side (optional): add __GL_SHADER_DISK_CACHE=0 in front of your gamescope launch option and quit the game within ~30 s of starting. Since this is the same bug as #2516, closing this one as a duplicate of #2516 (where #2542 is tracked) would keep it tracked in one place.
OK, I'll do that.