LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 01-06-2024, 09:39 AM   #1
rofr
LQ Newbie
 
Registered: Jan 2024
Distribution: Slackware
Posts: 3

Rep: Reputation: 0
SDL2_image-2.8.2 maybe breaks Valve Proton (WINE not tested)


TLDR:
After updating system, trying to run a game via Steam - Valve Proton, system apparently hangs(but not really - see below). Solved by reverting to previous version of SDL2_image (probably - see below). Unknown if this is a bad misconfig on my part or a bug in one of the upgraded packages.

Situation:
Last good update: Mon Jan 1 19:45:16 UTC 2024 (kernel 6.6.9)
Failed update: Thu Jan 4 20:54:16 UTC 2024 (cumulative from last good)
Kernel: Custom 6.6.9, Custom 6.6.10
DE: KDE Plasma 5 - xwayland, full wayland
Multilib: Yes, via slackpkg+
Drivers - graphics: Nvidia 535 series and 545("The Flickerati") series
Proton: Tested w. Experimental and 8.0-4

Initially, after update, system appeared to freeze after game launcher came up, no changes on screen, mouse unresponsive, keyboard caps-lock and num lock not changing status (assumed USB locked up). Unable to change to terminal. Upon further testing, playing a YT video in the background, sound playback continued normally.

Diving deeper, magic keys still worked, was able to issue SIGTERM to all processes. So basically a display hang?

Checked sddm's wayland-session.log, found nothing too obvious, was lead astray by Breeze theme error (extra line in "/usr/share/themes/Breeze/gtk-2.0/widgets/entry:70:" when it expected } ). Since I am functionally illiterate I read "pixmap" as "pixman", so... yeah...

Then ran Proton with debugging on, which was... mostly useless... sure, you get all sorts of info, but good luck finding out what it all means... One point of interest, last half of the log single line repeated in what appeared to be an infinite loop (sry, can't paste, log went shift-del).

Assumed PEBKAC, checked and saw SDL2_image, pixman and c-ares have multilib packages. Converted manually, still hanged (today's multilib upgrades Eric pushed made no change either).

Decided to try to revert to last known good config. Suspected X related stuff (Proton still needs x server) or l series packages. Reverted pixman-0-43-0 first, no change. Reverted SDL2_image-2.8.2, system returned to working configuration. Not sure if it's only SDL2_image, or a combination, since I violated "change one thing at a time, and one thing only".

Conclusions:
Managed to make it work, but I have no idea if the problem is a bad misconfiguration on my end, or a new and exciting package bug. I freely admit that I engaged in "Stupidity out of Convenience" and had nvidia installer mangle xorg.conf, and running the user account without .xinitrc. I'm still learning this Linux thing, so who knows what else is misconfigured.

Ideas on what went wrong/how to find out, anyone? Any way of having extended logging (did try kwin's QT_LOGGING_RULES, but I dunno if I used it right) and a good way of making it make sense? Googling the warnings/errors in mostly unproductive. Tbh, any linux issue I've had, best results were with site:linuxquestions.org, but this is kinda kwin and/or proton specific, so...


P.S. - Long time lurker, first time poster since I got it to "work for me", and, well, if somebody else has the same issue...
 
Old 01-07-2024, 03:53 PM   #2
Pithium
Member
 
Registered: Jul 2014
Location: Far side of the Oregon Trail
Distribution: Slackware64 15.0
Posts: 508

Rep: Reputation: 586Reputation: 586Reputation: 586Reputation: 586Reputation: 586Reputation: 586
Does this happen when running KDE in X11 mode (no wayland)? While Valve games should work in Wayland I know that they have configured their apps to prefer X11 when available. It's possible something is getting gummed up since you are running kwin_wayland. Since it is locking up the entire desktop rather than just the app you might want to try in the legacy (a.k.a. STABLE) environment.
 
Old 01-08-2024, 08:25 AM   #3
garpu
Senior Member
 
Registered: Oct 2009
Distribution: Slackware
Posts: 1,587

Rep: Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917
No problems here with proton starting and running. I had issues with swapping, but I think that happened long before the SDL-image update. I'm also on X11, though. It sounds like something to raise with Proton and valve: https://github.com/ValveSoftware/Proton/issues
 
Old 01-08-2024, 03:17 PM   #4
rofr
LQ Newbie
 
Registered: Jan 2024
Distribution: Slackware
Posts: 3

Original Poster
Rep: Reputation: 0
I am going to mark this solved, as further testing revealed that this SDL2_image version doesn't actually cause the problem, just makes it 100% reliable on wayland.

Switching to X11 is always an option, as you both mentioned. I'll play around some more, see if I can figure out if this is drivers/wayland/hardware, and decide then.

Thanks for the replies.
 
Old 01-08-2024, 06:45 PM   #5
garpu
Senior Member
 
Registered: Oct 2009
Distribution: Slackware
Posts: 1,587

Rep: Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917
If it is an SDL_image issue, then that's definitely something that should be bug-reported to Valve at the github.
 
Old 01-10-2024, 02:30 PM   #6
garpu
Senior Member
 
Registered: Oct 2009
Distribution: Slackware
Posts: 1,587

Rep: Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917
https://en-forum.guildwars2.com/topi...e/85/#comments Was this the problem you were having?
 
Old 01-10-2024, 03:58 PM   #7
rofr
LQ Newbie
 
Registered: Jan 2024
Distribution: Slackware
Posts: 3

Original Poster
Rep: Reputation: 0
Unfortunately, no... I have been refraining for posting updates, because I'm engaging in some major stupidity with ltrace right now, since it seem that as of now, only reverting works. While I was doing some testing, I decided to try X session of plasma, and results are the same there. The only difference is, on wayland everything screen related is frozen, but on X the mouse cursor is still responsive.

One difference wrt the thread you posted, downgrading pixman solved it for the guy, but not for me. I only got a working config after downgrading SDL2_image also, hence the name of the thread. I would test with SDL2_image only, but doing magic key SIGTERM and then logging in just to reboot(I don't know if firewall dies also, so, a precaution if you will) is a major annoyance.

Yesterday, I played around with Kwin debugging under wayland, adding a line in ~/.bash_profile:
Code:
export QT_LOGGING_RULES="kwin_*.debug=true"
The results being, at hang time, the log has two repeating lines:
Code:
kwin_core: KWin::XwaylandWindow(0x23cf310, windowId=0x4600005, surface=KWaylandServer::SurfaceInterface(0x24b8f50), caption="Launcher") true false false
kwin_core: PERMITTED KWin::XwaylandWindow(0x23cf310, windowId=0x4600005, surface=KWaylandServer::SurfaceInterface(0x24b8f50), caption="Launcher") true
I also ran Proton with PROTON_LOG=1, result at hang being:
Code:
969.919:0138:0148:trace:seh:NtGetContextThread 0xfffffffe: eax=000000de ebx=00000001 ecx=00000000 edx=00000000 esi=00000001 edi=0320f8e0
969.919:0138:0148:trace:seh:NtGetContextThread 0xfffffffe: ebp=0320f9f8 esp=0320f89c eip=7bc0c55c cs=0023 ss=002b flags=00000246
969.919:0138:0148:trace:seh:NtGetContextThread 0xfffffffe: ds=002b es=002b fs=0063 gs=006b
which repeats Ad-Infinitum until SIGTERM. That look like 32 bit processor registers(64 bit is rax?) and flags to me, and looking up seh, that may be a microsoft exception handling thingy, but I'm new at this, so who knows. Which seems to me like Proton and Kwin are caught in a loop - I'd expect them to just fail and be done with it. I haven't bothered to see if I can log CPU utilization, to see if they just hog one core, while the other 3 keep the kernel alive.

I did find descriptions of problems with 535 nvidia driver here, related here, and a description very similar to mine here, although it seems X11 specific. None of the described solutions worked in the wayland session.

So, as any reasonable person would do, knowing nothing about debugging in general, least of all on linux, I decided to look up some profiling and debugging tools. I'm not smart enough for ptrace, strace is for system calls, but ltrace was promising, since I have a known suspect library, that while it may not be the actual culprit, just makes the failure 100% reliable. I was always hoping to learn how to use GDB also, for my own purposes when dabbling in programming, but that plan was on hold for a while - need to get this system set up to my liking first.

SlackBuilds has a nice script for patching and building ltrace, so I modified that to my purposes. But, using the naive way to try to attach a trace to steam itself, and then follow the children to Proton was... well, naive... By itself, it crashes nicely... It is possible to run it against steam as described here on Arch wiki, even tho they don't mention ltrace in supported list. That kinda runs, but eventually fails after initial version check.

So that was kinda bad. Then I read up on the actual internal proton tooling, and if you use the Experimental beta with debug symbols, you can set the debug flag:
Code:
PROTON_DUMP_DEBUG_COMMANDS=1
which will write some nice shell scripts to set up the environment for winedbg --gdb to /tmp/proton-username. That started the .exe in debug mode, but, like I said, I haven't learned GDB yet, and, it seemed to me like it was tracking just the exe, and not the actual wine calls themselves? Got no useful output, but I did get a regular hang with the Launcher interface coming up and freezing.

So, doing another sensible thing, I modified the generated script by removing winedbg --gdb, and just kept the last shell magic that runs the actual .exe... I mean, what's the worst thing that could happen, I fork bomb myself?

Of course, ltrace was not happy, since a shell script is not an ELF... but of course, bash is, and if you trace it and it's children while executing the script...

In other words, I'm sitting on some 863KiB of plain text log that I need to grep, from startup until launcher screen hang

I wasn't going to post anything until I got a result, or if I failed due to lack of knowledge, I could just let the thread die quietly and pretend it didn't happen. But since you're following this issue and it seems there's some strange things going on elsewhere, figured might as well update you all on what I've been up to. If nothing else, someone that does this for a living might find it amusing
 
Old 01-10-2024, 07:08 PM   #8
garpu
Senior Member
 
Registered: Oct 2009
Distribution: Slackware
Posts: 1,587

Rep: Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917Reputation: 917
It definitely sounds like something that could be kicked up the flagpole to Valve/Proton on their github. They're good at routing threads, if it's in the wrong place, as well. I wondered if it was related to pixman, since it started about the time we got a pixman update, and the whole freeze at launch thing sounded similar. (Not sure if SDL-image is compiled against it?) It would also stand to reason why I'm not experiencing it (x11 and xfce4)
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
setcap works with Wine but not with Proton (Proton "ignores" it) Liemaeu Linux - Software 2 03-24-2021 08:18 AM
LXer: Steam Play Proton 4.11-9 is out with a few fixes, plus a new release of Proton GE LXer Syndicated Linux News 0 11-28-2019 06:12 PM
LXer: Want a more up to date Proton for Steam Play on Linux? Proton GE has a big new release out LXer Syndicated Linux News 0 09-04-2019 11:51 PM
[SOLVED] SDL2_image jpeg not loading on slackware 14.2 timsoft Slackware 6 10-13-2016 04:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 12:24 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration