Patreon Logo Support us on Patreon to keep GamingOnLinux alive. This ensures all of our main content remains free for everyone. Just good, fresh content! Alternatively, you can donate through PayPal Logo PayPal. You can also buy games using our partner links for GOG and Humble Store.
Title: Radeon desktop user experience?
HihiDanni 19 Nov 2020
Hi all, I've been using nVidia on Linux for a little over ten years now, and with all the problems with suspend/resume under KDE, the kernel 5.9 breakage, poor VR support, etc., I'd like to see if the experience is any better over on Team Red. But before I invest in a new Radeon GPU, I'd like to know what other people's experiences are. Namely here are some things I want to know about:

- Do you have driver control over Vsync? This is something we've always had with the nVidia binary blob, and I remember that on Intel/mesa it seemed like you could never really tell the driver to Vsync when you wanted Vsync, or to avoid Vsync if you didn't want it. It just did whatever it felt like, even if you tried to tell DRI otherwise.

- Does the KWin compositor do Vsync? (I have this under nVidia)

- Do fullscreen games do direct page flip? I.e. are they unredirected, and are they responsible for doing Vsync? And do they do that Vsync? (Also have this under nVidia)

- Does adaptive sync work? I have a Gsync/FreeSync monitor which has really improved frame timing in fullscreen mode.

- What's the windowed game experience like? What about with/without compositing? Is the framepacing good? How does it react to the Vsync settings in the game/compositor?

- Is Gamescope good for daily use? Does it support adaptive sync in windowed mode?

- Is the experience with OBS good? What happens to the display sync (what I see) when I stream/record with it? (on nVidia it seems to framelimit but not Vsync to the display) And what about the output? (on nVidia the OBS output seems to be Vsynced correctly). Do you get flashing corruption with some capture modes on AMD? (I do on nVidia)

- Do you ever have any issues with suspend/resume? Over on nVidia it would just get stuck for about a month or so, forcing me to do a hard reboot, and I'm still having issues with display/texture corruption when I wake that likely won't be fixed anytime soon.

- Do you have any compatibility issues with OpenGL games? Over time this is becoming less and less important due to Zink and the increase in games supporting Vulkan, but I'm still curious.

- Is there a good interface for changing driver settings?

Thanks in advance!
Shmerl 19 Nov 2020
1. You can control vsync both for Vulkan and OpenGL.

To force vsync:

# Vulkan
MESA_VK_WSI_PRESENT_MODE=fifo

# OpenGL
vblank_mode=3


Kwin vsync works much better than on Nvidia where it's messed up.

2. You can turn off compositing in X11 KWin. On Wayland there is no such concept.

3. Adaptive sync works on X11, not on Wayland yet (with KWin).

4. Not sure about windowed game experiene. I always make it full screen, but it's not a real fulscreen anyway - you get a window that takes most of the screen.

5. I haven't tested Gamescope or OBS.

6. Suspend / resume has no issues.

7. OpenGL works fine. Zink didn't yet reach high enough version of OpenGL to be useful for anything.

8. There is no single interface for everything, but some kernel settings can be set with corectrl and radeon-profile.

Last edited by Shmerl on 19 Nov 2020 at 11:08 pm UTC
HihiDanni 19 Nov 2020
Thanks for the responses so far!

 
# Vulkan
MESA_VK_WSI_PRESENT_MODE=fifo

# OpenGL
vblank_mode=3
This looks like it's using triple buffering. Is there a way to force double buffering with a page queue size of the minimum possible to reduce input lag?
Shmerl 19 Nov 2020
Where did you see info on triple buffering?

vblank_mode=3 simply means vsync on (for OpenGL):

https://dri.freedesktop.org/wiki/ConfigurationOptions/

Name: vblank_mode

Drivers: mga, r128, r200, radeon Synchronization with the vertical refresh can avoid visual "tearing" with fast motion. At the same time it limits the frame rate to (a fraction of) the vertical refresh rate. Applications can set a "swap interval" which means that buffer swaps occur no earlier than n vertical blanks after the previous swap. With this option you can disable swap intervals, choose a default swap interval of 0 or 1 or you can force the application to always wait for a vertical blank on every buffer swap:

0 = Never, FPS rulez!
1 = Application preference, default interval 0
2 = Application preference, default interval 1
3 = Application preference, always synchronize with refresh
Same for MESA_VK_WSI_PRESENT_MODE=fifo:

https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkPresentModeKHR.html

VK_PRESENT_MODE_FIFO_KHR specifies that the presentation engine waits for the next vertical blanking period to update the current image. Tearing cannot be observed. An internal queue is used to hold pending presentation requests. New requests are appended to the end of the queue, and one request is removed from the beginning of the queue and processed during each vertical blanking period in which the queue is non-empty. This is the only value of presentMode that is required to be supported.
Last edited by Shmerl on 19 Nov 2020 at 11:26 pm UTC
Shmerl 19 Nov 2020
If you want to control the number of backuffers in Vulkan explicitly, there is no variable for that yet.

See: https://gitlab.freedesktop.org/mesa/mesa/-/issues/184

You can control it in dxvk settings at least.

Last edited by Shmerl on 19 Nov 2020 at 11:28 pm UTC
Shmerl 19 Nov 2020
Anyway, if you have adaptive sync monitor, you don't want to enable vsync. Keep it off, but might want to limit the framerate to max monitor refresh rate may be to avoid overtaxing the GPU.

Libstrangle helps for that: https://gitlab.com/torkel104/libstrangle/
HihiDanni 19 Nov 2020
Quoting: ShmerlWhere did you see info on triple buffering?
My bad, I saw "FIFO" and mistook it for "mailbox".

Quoting: ShmerlAnyway, if you have adaptive sync monitor, you don't want to enable vsync. Keep it off, but might want to limit the framerate to max monitor refresh rate may be to avoid overtaxing the GPU.

Libstrangle helps for that: https://gitlab.com/torkel104/libstrangle/
My experience with adaptive sync (at least, nVidia G-Sync) has been that you actually do want to enable Vsync in the game, as otherwise you will still get tearing. So you want to use Vsync plus set the display to the highest refresh rate you want to be able to hit. Adaptive sync just means that if a regular V-blank period is missed, that it can still Vsync on command instead of waiting for the next blanking period. I also haven't needed to limit the FPS either.
Shmerl 20 Nov 2020
I never used Gsync, but standard adaptive sync that Mesa uses requires turning vsync off to work.

The whole point of adaptive sync is to bypass vsync on any specific rate and make the monitor itself sync to the framerate. So it makes sense to me that vsync should be off for it.

If you enable vsync, limiting fps won't make sense, because it will capped at your monitor max refresh rate. If you turn vsync off to enable adaptive sync, framerate can shoot above monitor's max refresh rate. That's where framerate limiter comes handy.

Last edited by Shmerl on 20 Nov 2020 at 12:28 am UTC
HihiDanni 20 Nov 2020
Quoting: The_Aquabatwhat settings you want to change??
Mainly I want to be able to force anisotropic filtering to 16x for all programs, because there's no point in not using it (I haven't noticed any performance or graphical issues with it on), and I hate how floor/wall textures blur at a distance with it disabled. A GUI for selecting Vsync would also be nice, although having a CLI option for it is good enough. Also useful to be able to manually set per-app settings, though I haven't been doing much of that.
Xpander 20 Nov 2020
If you have a real Gsync monitor, that wont work with AMD GPU afaik. Nvidia naming stuff and forcing to monitor vendors is a bit odd. Many monitors call Freesync as Gsync nowadays or Gsync-Compatible. If its the Gsync compatible, then it should work fine on AMD. with freesync/GsyncCompatible you dont enable vsync for it to work.
I use Nvidia GPU and have Freesync/GsyncCompatible monitor and i have to run it without vsync if i want to use it.
Shmerl 20 Nov 2020
Quoting: HihiDanniMainly I want to be able to force anisotropic filtering to 16x for all programs
That can be done like this:

# Vulkan
RADV_TEX_ANISO=16

# OpenGL
AMD_TEX_ANISO=16 
melkemind 25 Nov 2020
  • Supporter
I just purchased a 6800 XT last week, so this has been my first experience with a Radeon card in many years. One key thing to know is that there is no official graphical control panel from AMD, so you'll be doing a long of config file work. I personally enjoy that part of Linux anyway, so it wasn't bad for me.

Desktop usage seems to work light years better than Nvidia. I had so many hacks with my Nvidia cards to keep apps from tearing, animations not performing well, etc. AMD's desktop support seems to be flawless. Mind you, I couldn't use the built-in Mesa driver because it's not available for my card yet, but the open AMDGPU driver from AMD's website worked.

Freesync is the biggest pain. I just finally got it working last night after I found out you have to disable compositing to get it to work. I believe it does not work in windowed mode.

Performance wise, it's hard to tell because I went from a GTX 1070 to an RX 6800 XT. Everything is maxed out on every game for me at 1440p. I soon realized I had to download vulkan drivers separately (something that was in the release notes for the driver but not explained well). Most of the ins and outs I had to learn from forums like this one, so there is a bit of a learning curve. Obviously, it'll be easy for older cards since the driver is literally built into the kernel.

If there's anything I didn't answer, I'd be happy to share more of my experience.
tuubi 25 Nov 2020
User Avatar
Quoting: melkemindMind you, I couldn't use the built-in Mesa driver because it's not available for my card yet, but the open AMDGPU driver from AMD's website worked.
According to Liam's launch day article, Linux 5.9, Mesa 20.2 and LLVM 11 should suffice. They've all been out for a while.

You can get the latest kernels on Ubuntu derivatives from Ubuntu's kernel PPA (easy to install and manage with the aptly named [Ubuntu Mainline Kernel Installer](https://github.com/bkw777/mainline) ), and Mesa + LLVM from [Kisak's Mesa PPA](https://launchpad.net/~kisak/+archive/ubuntu/kisak-mesa). If you don't like messing with PPAs, I guess the proprietary AMDGPU driver is a valid option.
HihiDanni 26 Nov 2020
Quoting: melkemindFreesync is the biggest pain. I just finally got it working last night after I found out you have to disable compositing to get it to work.
You probably want compositing to be disabled for full-screen anyway, because then you'll have control over Vsync, lower latency, and better framepacing. In vanilla KWin, you'll want to enable "Allow applications to block compositing". There's also the kwin-lowlatency fork which I highly recommend, as it runs compositing at the display refresh rate and reintroduces the option to automatically disable compositing for full-screen applications.
Sojiro84 26 Nov 2020
Quoting: Shmerl
Quoting: HihiDanniMainly I want to be able to force anisotropic filtering to 16x for all programs
That can be done like this:

# Vulkan
RADV_TEX_ANISO=16

# OpenGL
AMD_TEX_ANISO=16 
So I put this in my .profile and that should take care of it right? Like:

# Vulkan
export RADV_TEX_ANISO=16

# OpenGL
export AMD_TEX_ANISO=16
Shmerl 26 Nov 2020
Quoting: Sojiro84So I put this in my .profile and that should take care of it right? Like:

# Vulkan
export RADV_TEX_ANISO=16

# OpenGL
export AMD_TEX_ANISO=16
Yes, if you want that to be just always enabled for everything. I usually put such exports in my game launchers scripts.
melkemind 26 Nov 2020
  • Supporter
Quoting: HihiDanni
Quoting: melkemindFreesync is the biggest pain. I just finally got it working last night after I found out you have to disable compositing to get it to work.
You probably want compositing to be disabled for full-screen anyway, because then you'll have control over Vsync, lower latency, and better framepacing. In vanilla KWin, you'll want to enable "Allow applications to block compositing". There's also the kwin-lowlatency fork which I highly recommend, as it runs compositing at the display refresh rate and reintroduces the option to automatically disable compositing for full-screen applications.
Thanks for bringing that to my attention. I've just been doing Alt+Shift+F12 every time I want to play a game. Having it done automatically would be awesome.
Shmerl 26 Nov 2020
Yeah, that's a common point - to enable adaptive sync, you need to disable compositing if you have X11 session. I just also do with Alt+Shift+F12.

"Allow applications to block composting" setting is fine and works with native games or video players, but it doesn't work for Wine games somehow. So I just do it manually in such cases.

Last edited by Shmerl on 26 Nov 2020 at 10:58 pm UTC
HihiDanni 27 Nov 2020
Quoting: ShmerlYeah, that's a common point - to enable adaptive sync, you need to disable compositing if you have X11 session. I just also do with Alt+Shift+F12.

"Allow applications to block composting" setting is fine and works with native games or video players, but it doesn't work for Wine games somehow. So I just do it manually in such cases.
You can disable compositing on a per-app basis by right-clicking the titlebar and going to More Actions -> Configure Special Application Settings. There you can add a "Block compositing" property. Make sure it's set to "Force" (not "Do Not Affect"), and "Yes".
While you're here, please consider supporting GamingOnLinux on:

Reward Tiers: Patreon Logo Patreon. Plain Donations: PayPal Logo PayPal.

This ensures all of our main content remains totally free for everyone! Patreon supporters can also remove all adverts and sponsors! Supporting us helps bring good, fresh content. Without your continued support, we simply could not continue!

You can find even more ways to support us on this dedicated page any time. If you already are, thank you!
Login / Register