You are not logged in.

#1 2023-10-01 17:30:48

nihal
Member
Registered: 2023-10-01
Posts: 4

[SOLVED] PRIME defaults to wrong GPU, broken rendering

After rebooting my system (laptop with integrated Intel GPU and dedicated AMD GPU) a few hours ago, PRIME appears to default to the AMD GPU and rendering for a lot (but not all) applications on this GPU seems to be completely broken.

Some applications like Firefox, Okular, keepassxc and my terminal appear to be working as normal, while other applications like glxgears, Chromium or any Electron-based application just render as flickering lines (example screenshot of glxgears). Running these applications with 'DRI_PRIME=1' seems to use the Intel graphics card instead, which "solves" the problem.

Has anyone experienced this problem before or are there any suggestions on what I could do? Thanks in advance :-)

I'm using Xorg with awesome as window manager in case it matters. The system is fully updated and rebooted. Some (possibly relevant?) output:

$ xrandr --listproviders
Providers: number : 2
Provider 0: id: 0x47 cap: 0xb, Source Output, Sink Output, Sink Offload crtcs: 4 outputs: 5 associated providers: 1 name:Intel
Provider 1: id: 0xad cap: 0xf, Source Output, Sink Output, Source Offload, Sink Offload crtcs: 5 outputs: 0 associated providers: 1 name:AMD Radeon 500 Series @ pci:0000:03:00.0
$ DRI_PRIME=0 glxinfo | grep "OpenGL renderer" # same output when not specifying 'DRI_PRIME' at all
OpenGL renderer string: AMD Radeon 500 Series (polaris12, LLVM 16.0.6, DRM 3.54, 6.5.5-arch1-1)
$ DRI_PRIME=1 glxinfo | grep "OpenGL renderer"
OpenGL renderer string: Mesa Intel(R) UHD Graphics 620 (WHL GT2)

Last edited by nihal (2023-10-01 22:23:21)

Offline

#2 2023-10-01 20:49:43

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 75,494

Re: [SOLVED] PRIME defaults to wrong GPU, broken rendering

Offline

#3 2023-10-01 21:43:14

nihal
Member
Registered: 2023-10-01
Posts: 4

Re: [SOLVED] PRIME defaults to wrong GPU, broken rendering

seth wrote:

Please post your Xorg log

https://pastebin.com/H91QRjJK

Offline

#4 2023-10-01 21:54:59

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 75,494

Re: [SOLVED] PRIME defaults to wrong GPU, broken rendering

The server is running on the intel chip.

[    65.943] (EE) AIGLX error: dlopen of /usr/lib/dri/i965_dri.so failed (/usr/lib/dri/i965_dri.so: cannot open shared object file: No such file or directory)
[    65.943] (EE) AIGLX error: unable to load driver i965
[    65.946] (II) IGLX: Loaded and initialized swrast
[    65.946] (II) GLX: Initialized DRISWRAST GL provider for screen 0

Get rid of xf86-vide-intel, it's likely the cause of the broken rendering.
You may or not also want to drop xf86-video-amdgpu

Reg. the glxinfo output, no idea how or why or whether the broken intel setup could cause the posted results, if you've remaining problems after dropping xf86-video-intel

(printenv; glxinfo -B) | curl -F 'file=@-' 0x0.st

Possibly also an updated Xorg log.

The disk UUIDs are btw. not sensitive data, the purely prevent collisions.
printenv will reveal you user name, which is maybe embarassing, but likewise not sensitive.

Offline

#5 2023-10-01 22:23:05

nihal
Member
Registered: 2023-10-01
Posts: 4

Re: [SOLVED] PRIME defaults to wrong GPU, broken rendering

seth wrote:

Get rid of xf86-vide-intel, it's likely the cause of the broken rendering.
You may or not also want to drop xf86-video-amdgpu

Reg. the glxinfo output, no idea how or why or whether the broken intel setup could cause the posted results

Thank you so much for the quick help! Removing xf86-video-intel and rebooting did indeed solve the issues. Applications are rendering properly again and DRI_PRIME=[0|1] results in the correct graphics card being used (according to glxinfo).

Offline

Board footer

Powered by FluxBB