Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.0.22rc1 regression in Tomb Raider (2013): black screen/unresponsive when loading game, "Error sending request: Resource temporarily unavailable" #5529

Closed
smcv opened this issue Apr 13, 2022 · 7 comments
Milestone

Comments

@smcv
Copy link
Contributor

smcv commented Apr 13, 2022

Debian 10, GNOME/Wayland, AMD GPU, Mesa 18.3.6 (I've been testing SDL 2.0.22rc1 on the oldest still-supported Wayland-by-default environment I could find, hence the old versions).

To reproduce:

  • Have a saved game (in case it matters, mine is in the first level shortly after being able to walk around for the first time, while doing puzzles with a burning torch and waterfalls)
  • Use the Steam Linux Runtime compatibility tool, which runs in a Debian-10-based container with an up-to-date version of SDL
  • Launch the game with SDL_VIDEODRIVER=wayland
  • Continue from the saved game

Expected result:

  • Main menu disappears
  • Mostly-black loading screen with gameplay tips
  • Game loads

Actual result:

  • Main menu disappears, leaving a black screen
  • The loading screen is not rendered
  • The game becomes unresponsive
  • Error sending request: Resource temporarily unavailable is logged to the game's stderr

This appears to be genuinely a regression in 2.0.22rc1: doing the same with the 2.0.20 from Steam Linux Runtime "soldier" version 0.20220329.49, forcing Wayland via SDL_VIDEODRIVER=wayland, works fine.

2.0.22rc1 with SDL_VIDEODRIVER=x11 also works fine, so this is specific to using Wayland and 2.0.22rc1.

@flibitijibibo
Copy link
Collaborator

This sounds like #4769, where it hangs without presenting and causes a timeout. There's an issue filed for libwayland to try and buffer some things to prevent this from happening.

@sulix
Copy link
Contributor

sulix commented Apr 14, 2022

I can't reproduce this exactly, also under nVidia (GTX 1060, 510.60.02)/Wayland, with openSUSE Tumbleweed (20220412) and KDE/KWin (5.24.4). My savegame's also later in the game (just before the end), but I doubt that matters.

But, note that:

That being said, with NVIDIA/egl-wayland#53 Tomb Raider 2013 is working perfectly under wayland with SDL's current git HEAD (55a4e1d).

(Also, note that the game's launcher window uses X11 regardless of SDL_VIDEODRIVER.)

My suspicion is that this is likely an nVidia/Wayland issue, though what change in SDL triggered it, I'm not sure.

@flibitijibibo
Copy link
Collaborator

In addition to the above it may also be related to #5536, where libdecor seems to compound the event queue problem in such a way that it breaks harder on GNOME than it does elsewhere. Not sure if libdecor's status changed recently in the runtime, that might be what caused this? 2.0.22's changes have mostly been fixes for different window types and scales, with the event system not changing all that much (if at all; I know output events got changed but that's more a startup thing).

@smcv
Copy link
Contributor Author

smcv commented Apr 18, 2022

Sorry, yes, this might be a SDL2-with-libdecor regression rather than genuinely a 2.0.22 regression. The production runtime has SDL 2.0.20 compiled without libdecor support, and my test runtime had several changes compared with the production runtime: libdecor added, libwayland upgraded from 1.16 to 1.18 (as a dependency for libdecor and the new SDL), and SDL upgraded to 2.0.22rc1 and compiled with libdecor.

Your theory sounds plausible, and at some point I'll try some other combinations to confirm whether the regression was in the SDL code, or in the enabled/disabled status of its libdecor code path. I didn't get as far as trying this particular game on NVIDIA.

@sulix
Copy link
Contributor

sulix commented Apr 18, 2022

FWIW, I was able to reproduce the black screen on loading once, with libdecor CSD force-enabled, in a window. It worked when I re-ran it, though, and it hasn't happened since, so I wasn't able to debug it much further.

@slouken
Copy link
Collaborator

slouken commented Apr 18, 2022

Wayland is no longer the default as of 254fcc9. I'm going to close this for 2.0.22, but I'll label it "wayland regression" so we can re-examine this later as needed.

@slouken slouken closed this as completed Apr 18, 2022
@slouken slouken added this to the 2.0.22 milestone Apr 18, 2022
@smcv
Copy link
Contributor Author

smcv commented Apr 19, 2022

For what it's worth, moving from 2.0.22rc1 to 02225aa seems to have avoided this failure mode in some (admittedly rather brief) testing, even with Wayland forced via SDL_VIDEODRIVER=wayland (and I can tell it's working, because I get a black libdecor window decoration, rather than the light grey GNOME Shell window decoration I see on X11 apps).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants