News for hackers. Stuff that matters.
Re:HW accelerated Xwayland rendering for Nvidia merged by michaelmrose on Friday April 09, 2021 @04:08PM (#26755445)
You said Xorg is a network system twice and I don't think you did enough research once. Wherein client and server are local it doesn't doesn't communicate via the network stack. The problem you imagine exists only in your imagination not reality.

I don't care if xorg runs as root and I don't need to run an instance of xorg per application I simply install software from trusted sources and haven't managed to get malware between 2003 and now. I also didn't have issues with tearing in 2003 and I don't now.

Generally speaking QT and GTK and other toolkits must concern themselves with the details of X others concern themselves with QT or GTK as they would under wayland. It is extremely likely that all players in the overall ecosystem who never had to specifically worry about X in many years have had more issues, work, and tears from wayland development than they would have had for the remainder of the next century with X.

This is nearly entirely about presenting a saner stable base to improve the work for a tiny number of people actually developing the graphics stack in Linux to build upon and unfortunately they made poor design decisions at the start that have led to it taking 12 years and still not being ready for prime time in some ways.

After doing the necessary research to understand the topic you could construct another post about the shortcomings of X that is actually factually correct but it would still be beside the point. Wayland would still be a poor work that squandered a lot of the opportunity of a clean slate despite its authors being in perhaps the best position possible to do so. In 20 years Linux if it exists on the desktop will be a weird opaque overengineered system that works when it works and is impossible for an end user to understand why it is misbehaving when it doesn't.

On the bright side due to package management the windows solution of pave over the install and start over could probably be configured to automatically reinstall all your software for you!

Re:HW accelerated Xwayland rendering for Nvidia merged by jrm4 on Friday April 09, 2021 @05:15PM (#26756277)
After a few years of wondering about the "why," I find this comment very illustrating; it feels like Wayland is one of many Linux related efforts (like Gnome and KDE) that are not particularly interested in a high level of interoperability and/or long term durability. Instead, the goal is more in the direction of trying to make their preferred way of things more dominant in the ecosystem. Now, if those efforts are actually good at it then more power to them. But most of the time, that doesn't happen, and I think it harms the Linux ecosystem, one that I am a fan of, overall.
Re:HW accelerated Xwayland rendering for Nvidia merged by kaba0 on Friday April 09, 2021 @10:03PM (#26758316)
How does it harm the ecosystem to place the fundamental abstraction of the goddamn DISPLAY server over something that actually was created after GPUs was a thing?

The X server is maxed out, or as a core maintainer said, you can only apply this many lipstick to a pig. It is fundamentally broken. But the X api is not, it will be supported forever in terms of XWayland. Which is a net win, we get proper graphics, and apps will be backward compatible.

Re:HW accelerated Xwayland rendering for Nvidia merged by destructionator on Friday April 09, 2021 @10:10PM (#26758350)
> It is fundamentally broken.

The Wayland developers disagree with you:

https://wayland.freedesktop.org/faq.html#heading_toc_j_5

"It's entirely possible to incorporate the buffer exchange and update models that Wayland is built on into X."

They themselves say they could have fixed X. They just didn't want to. And now they've predictably just made a new mess.

Re:HW accelerated Xwayland rendering for Nvidia merged by the_why_of_y on Saturday April 10, 2021 @05:20AM (#26760155)
The problem with X11 was never that you can't add things to it, the problem is that you can't remove things from it.
Re:HW accelerated Xwayland rendering for Nvidia merged by destructionator on Saturday April 10, 2021 @08:42AM (#26761057)
First, this isn't true - watch the youtube the other person in this thread put where he tells a story about how they deleting about 1/3 of the code (15:19), but secondly even if they didn't, why is that a problem?

Breaking user's applications isn't actually a virtue.

Re:HW accelerated Xwayland rendering for Nvidia merged by kaba0 on Saturday April 10, 2021 @03:27AM (#26759660)
Re:HW accelerated Xwayland rendering for Nvidia merged by wander_homer on Saturday April 10, 2021 @09:47AM (#26761469)
Did you watch and understand it? This presentation is nothing but a highly one-sided and subjective talk, which gladly bends the truth or leaves out crucial details to get a good laugh from the audience.

Take the whole part about "X terrible IPC" and slow startup time as an example. It's portrayed as if slow startup time is an inherent flaw of X due to blocking IPC calls. However he forgot to mention, that non-blocking calls had been there for years and big projects like Qt were using them exclusively instead of the blocking Xlib calls. Then he goes on to say that Chromium's startup time is so slow because at minimum it waits half a second for replies from the X server. So let's get some current numbers on a T420s for starting up Chromium and immediately closing it:

  Weston + Chromium (Wayland mode): 731.3 ms ±  39.4 ms
  Sway + Chromium (Wayland mode): 688.2 ms ±  22.7 ms
  Sway + Chromium (XWayland): 667.2 ms ±  16.6 ms
  X.org + i3 + Chromium: 661.3ms ±  17.2 ms
I was actually surprised to see how little difference there is, if there's any at all.

So either his numbers don't apply anymore and X.org is not a bottleneck anymore, or Wayland became a similar bottleneck, or his numbers never made sense in the first place, especially since he never bechmarked the Wayland part.

Edit: On GNOME Shell Chromium also starts slightly faster with X.org with 0.6 - 0.7s and > 0.7s in Wayland mode.

*updated benchmark results with the actual results from hyperfine (10 runs each)

Re:HW accelerated Xwayland rendering for Nvidia merged by kaba0 on Saturday April 10, 2021 @12:12PM (#26762539)
The video is quite old. And I think you should add a compositor on top of i3 to measure the same thing.

The whole point of the talk was that when a compositor is used (which should absolutely be used because with increasing resolutions tearing will just get more visible), X has pretty much a useless role in the whole situation. That is, you’ve got yourself an architectural problem. Which is no surprise, X had been here forever. But maybe it should no longer the be the abstraction we build our graphics on.

Re:HW accelerated Xwayland rendering for Nvidia merged by wander_homer on Saturday April 10, 2021 @12:26PM (#26762651)
With X.org + i3 + picom (GLX backend, animations and vsync enabled) I get: 665.8 ms ± 19.3 ms

So it doesn't seem to have any significant influence either.

Re:HW accelerated Xwayland rendering for Nvidia merged by kaba0 on Saturday April 10, 2021 @12:57PM (#26762939)
Thanks for benchmarking, but as I mentioned, this was/is not a significant problem that would give way for Wayland. What I wrote in the second part of my comment is.