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. You can also buy games using our partner links for GOG and Humble Store.
We do often include affiliate links to earn us some pennies. See more here.

Another exciting moment for fans of Wayland and the future of Linux, especially if you're an NVIDIA user, as the work to provide hardware accelerated rendering for NVIDIA GPUs was merged in for Xwayland. We've been following this work for a while, as an upcoming NVIDIA driver will have the code in for everything to be in place (likely NVIDIA 470).

To save you clicking around, this is what NVIDIA engineer Erik Kurzinger said about the patches:

These two patches are intended to accompany upcoming support in the proprietary NVIDIA driver for hardware accelerated GL and Vulkan rendering with Xwayland. They shouldn't interfere with the current swrast-based GL support, so once the driver-side changes are out the door things should just start working. I wanted to send these out for consideration first, though, in case anyone has any substantial concerns with the general approach. See the commit messages for further details on the implementation.

Performance should be roughly on-par with native X11 based on the benchmarking I've done. There's still an annoying extra copy required for presentation of windowed applications, but the impact doesn't appear to be significant, and full-screen applications won't have that issue (provided the compositor supports the required zwp_linux_dmabuf_v1 interface).

Since more distributions are moving over to Wayland from the old Xorg, this is a huge and important step. Even Ubuntu is targetting Wayland as the default for the upcoming Ubuntu 21.04 release. Still, it will be some time before all the major distributions have releases out with this new Xwayland support in for NVIDIA. It's possible we will see this land in the likes of Ubuntu 21.10, so more likely towards the end of this year.

You can see the Merge Request here.

Other interesting upcoming work includes another Merge Request that's not yet merged, which would enable the loading of alternative GBM backends.

Article taken from GamingOnLinux.com.
34 Likes
About the author -
author picture
I am the owner of GamingOnLinux. After discovering Linux back in the days of Mandrake in 2003, I constantly came back to check on the progress of Linux until Ubuntu appeared on the scene and it helped me to really love it. You can reach me easily by emailing GamingOnLinux directly.
See more from me
The comments on this article are closed.
19 comments
Page: «2/2
  Go to:

redneckdrow Apr 12, 2021
I'm really glad it's finally happening, but I wonder just how necessary the switch to Wayland actually is. Dedoimedo released a rather thoughtful article on the subject, and I tend to agree with him on several points.

Warning! Grumpy lecturing ahead:
Spoiler, click me

Yes X's old code is a possible attack vector, but I don't know of any attacks ever targeting the display server in all the time I've been using Linux. Most attacks/malware seem to be aimed at headless servers and tend to be tailor made to exploit out of date installations. Besides, Wayland could have its own security concerns to deal with.

I don't get the need to reinvent the wheel here.

The desktop user just needs to be careful not to run scripts without checking them for things that look out of place. They're typically pathetically obvious even to people like me who know next to nothing about scripting. Also, never symlink libraries or put old libraries in /usr/lib or other global directories, that can lead to some real haberdashery.

Also, if you can help it, don't run GUI programs as root (pkexec doesn't work correctly with every program) anyway. Wayland does seem to protect the user from this gotcha, from what I read; I'll give it that at least.

Is there any reason to use Wayland other than the perception of security for the end user? I can't get a straight answer. Does XWayland still have any noticeable overhead when gaming? I'll give it a try when the new NVIDIA driver goes stable.

All things considered, I'll give Wayland a fair shake. I'll probably post my experience in the forums. If you've read this far, thank you. It took me 30 minutes to type this with my one good hand, and I appreciate it.
CatKiller Apr 13, 2021
View PC info
  • Supporter Plus
Quoting: redneckdrowIs there any reason to use Wayland other than the perception of security for the end user?

X is entirely and completely unmaintained. Its known flaws will never be fixed; flaws discovered in the future will never be fixed. The people that used to work on it don't want to any more, and only work on Wayland now. Xorg 1.21 hasn't been released because there's no one interested enough to do so. It's kicked the bucket, shuffled off its mortal coil, run down the curtain, and joined the choir invisible.
Purple Library Guy Apr 13, 2021
Quoting: CatKiller
Quoting: redneckdrowIs there any reason to use Wayland other than the perception of security for the end user?

X is entirely and completely unmaintained. Its known flaws will never be fixed; flaws discovered in the future will never be fixed. The people that used to work on it don't want to any more, and only work on Wayland now. Xorg 1.21 hasn't been released because there's no one interested enough to do so. It's kicked the bucket, shuffled off its mortal coil, run down the curtain, and joined the choir invisible.
This . . . is an ex-X!
Purple Library Guy Apr 13, 2021
Quoting: redneckdrowI'm really glad it's finally happening, but I wonder just how necessary the switch to Wayland actually is. Dedoimedo released a rather thoughtful article on the subject, and I tend to agree with him on several points.

Warning! Grumpy lecturing ahead:
Spoiler, click me

Yes X's old code is a possible attack vector, but I don't know of any attacks ever targeting the display server in all the time I've been using Linux. Most attacks/malware seem to be aimed at headless servers and tend to be tailor made to exploit out of date installations. Besides, Wayland could have its own security concerns to deal with.

I don't get the need to reinvent the wheel here.

The desktop user just needs to be careful not to run scripts without checking them for things that look out of place. They're typically pathetically obvious even to people like me who know next to nothing about scripting. Also, never symlink libraries or put old libraries in /usr/lib or other global directories, that can lead to some real haberdashery.

Also, if you can help it, don't run GUI programs as root (pkexec doesn't work correctly with every program) anyway. Wayland does seem to protect the user from this gotcha, from what I read; I'll give it that at least.

Is there any reason to use Wayland other than the perception of security for the end user? I can't get a straight answer. Does XWayland still have any noticeable overhead when gaming? I'll give it a try when the new NVIDIA driver goes stable.

All things considered, I'll give Wayland a fair shake. I'll probably post my experience in the forums. If you've read this far, thank you. It took me 30 minutes to type this with my one good hand, and I appreciate it.
I just read that article; it strikes me as a bit of a strawman. It claims that the only reasons for developing Wayland were security and, I dunno, novelty or something. As I understand it, there actually are quite a few things that X is not good at doing or not capable of doing because it is so antiquated, which some people wanted done, and which Wayland was built to be able to do. So whether those things are in your use-case or not, they do exist and are part of the point of Wayland--characterizing it as an inadequate replacement whose only point is security, is fundamentally inaccurate. And really, considering that the people who do Wayland are also the people who used to do X, it seems to me fairly unlikely that they would have gone to the effort of starting a whole new thing just for hypothetical security.

Rather, in real life there seem to have been many efforts to give X upgrades and overhauls to deal with various issues, and the developers finally hit a wall where they didn't see any way forward except to start fresh. I'm not a techie, but on a non-techie level I've been following all this for many years, and it seems the problem is that how applications, graphics cards and their drivers and so on want to interact with screens has changed a lot since X was first written; the whole paradigm just doesn't apply any more and getting it to pretend gradually became kludge upon kludge upon kludge.
CatKiller Apr 13, 2021
View PC info
  • Supporter Plus
Quoting: Purple Library Guy
Quoting: CatKiller
Quoting: redneckdrowIs there any reason to use Wayland other than the perception of security for the end user?

X is entirely and completely unmaintained. Its known flaws will never be fixed; flaws discovered in the future will never be fixed. The people that used to work on it don't want to any more, and only work on Wayland now. Xorg 1.21 hasn't been released because there's no one interested enough to do so. It's kicked the bucket, shuffled off its mortal coil, run down the curtain, and joined the choir invisible.
This . . . is an ex-X!
"X.parrot Server" occurred to me after I'd hit the Post button.
CatKiller Apr 13, 2021
View PC info
  • Supporter Plus
Quoting: Purple Library GuyRather, in real life there seem to have been many efforts to give X upgrades and overhauls to deal with various issues, and the developers finally hit a wall where they didn't see any way forward except to start fresh. I'm not a techie, but on a non-techie level I've been following all this for many years, and it seems the problem is that how applications, graphics cards and their drivers and so on want to interact with screens has changed a lot since X was first written; the whole paradigm just doesn't apply any more and getting it to pretend gradually became kludge upon kludge upon kludge.
Yep, pretty much.

X was state of the art in 1984. For comparison, the GPU as we understand it now was invented some 15 years later.

The biggest change is how multiple windows are combined - composited - to create something that's drawn on a screen. That's an extension for X rather than part of the main thing - support for bitmapped fonts and being able to draw dashed lines are part of the main thing - but it's where all the actual work is done. And the other parts of the functionality of X have changed, too: input handling is completely different now, and throwing bitmaps over the network is not really terribly efficient.

So Wayland makes the compositor the central part, uses more relevant input and output handing, and gets rid of the network stuff entirely.

There are aspects of Wayland's design, implementation, and history that, in my view, have hampered its adoption and desirability. But it's what we've got, since Mir didn't take off and X is no longer fit for purpose, so we have to make the best of it.
slaapliedje Apr 13, 2021
Quoting: CatKiller
Quoting: Purple Library GuyRather, in real life there seem to have been many efforts to give X upgrades and overhauls to deal with various issues, and the developers finally hit a wall where they didn't see any way forward except to start fresh. I'm not a techie, but on a non-techie level I've been following all this for many years, and it seems the problem is that how applications, graphics cards and their drivers and so on want to interact with screens has changed a lot since X was first written; the whole paradigm just doesn't apply any more and getting it to pretend gradually became kludge upon kludge upon kludge.
Yep, pretty much.

X was state of the art in 1984. For comparison, the GPU as we understand it now was invented some 15 years later.

The biggest change is how multiple windows are combined - composited - to create something that's drawn on a screen. That's an extension for X rather than part of the main thing - support for bitmapped fonts and being able to draw dashed lines are part of the main thing - but it's where all the actual work is done. And the other parts of the functionality of X have changed, too: input handling is completely different now, and throwing bitmaps over the network is not really terribly efficient.

So Wayland makes the compositor the central part, uses more relevant input and output handing, and gets rid of the network stuff entirely.

There are aspects of Wayland's design, implementation, and history that, in my view, have hampered its adoption and desirability. But it's what we've got, since Mir didn't take off and X is no longer fit for purpose, so we have to make the best of it.
I swear I read at some point that they were planning on eventually replacing the networking / forwarding capabilities (they are extremely useful on occasion).

My understanding also is that Xorg is not 100% dead, it's just resting. They've nailed it to the perch, so to speak. Beautiful plumage.

They are maintaining it, there were some modules updated like a month or so ago. I'm a firm believer still that X was fine, and they just wanted something new to play with, so Wayland was born. I mean Xorg is an extremely stable / old code base, and who doesn't want to occasionally have something new to play with?

My test of whether or not I'm running Wayland now, as far too often I start finding random breakages, and random distributions default to Wayland now, I do an alt+F2 and 'r' in Gnome, and if it whines that I can't restart Gnome, I know I'm running in Wayland, as for some reason you can't reload Gnome in Wayland...
CatKiller Apr 13, 2021
View PC info
  • Supporter Plus
Quoting: slaapliedjeMy understanding also is that Xorg is not 100% dead, it's just resting. They've nailed it to the perch, so to speak. Beautiful plumage.

They are maintaining it, there were some modules updated like a month or so ago.
What changes there have been are to make XWayland work, which is being spun out into its own thing so that it will actually be released. Pining for the fjords.
chr Apr 17, 2021
Quoting: redneckdrowI'm really glad it's finally happening, but I wonder just how necessary the switch to Wayland actually is. Dedoimedo released a rather thoughtful article on the subject, and I tend to agree with him on several points.

Warning! Grumpy lecturing ahead:
Spoiler, click me

Yes X's old code is a possible attack vector, but I don't know of any attacks ever targeting the display server in all the time I've been using Linux. Most attacks/malware seem to be aimed at headless servers and tend to be tailor made to exploit out of date installations. Besides, Wayland could have its own security concerns to deal with.

I don't get the need to reinvent the wheel here.

The desktop user just needs to be careful not to run scripts without checking them for things that look out of place. They're typically pathetically obvious even to people like me who know next to nothing about scripting. Also, never symlink libraries or put old libraries in /usr/lib or other global directories, that can lead to some real haberdashery.

Also, if you can help it, don't run GUI programs as root (pkexec doesn't work correctly with every program) anyway. Wayland does seem to protect the user from this gotcha, from what I read; I'll give it that at least.

Is there any reason to use Wayland other than the perception of security for the end user? I can't get a straight answer. Does XWayland still have any noticeable overhead when gaming? I'll give it a try when the new NVIDIA driver goes stable.

All things considered, I'll give Wayland a fair shake. I'll probably post my experience in the forums. If you've read this far, thank you. It took me 30 minutes to type this with my one good hand, and I appreciate it.

I agree with that article that the end-user experience is critical and that maybe we shouldn't deploy Wayland until it is 99.999% ready. But I disagree with the idea that Wayland exists due to re-writing things for the sake of re-writing things.

For me, the main bit is what Dedoimedo actually mentioned in their article - maintainability. Things that are not maintainable take huge amounts of extra effort to fix, improve and even keep working. So that is a perfectly good reason for redoing ancient software with outdated paradigms.
While you're here, please consider supporting GamingOnLinux on:

Reward Tiers: Patreon. Plain Donations: 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!
The comments on this article are closed.