Wayland: "Move fast and break things" as a moral imperative
By Drew Default
Wayland breaks a lot of stuff, and in ways that are difficult to fix. This can have a chilling effect on users, particularly those on older or slower hardware. Wayland ostensibly supports several dozen extensions, but only the GNOME-blessed extensions can be reasonably expected to work. As someone who has tried to use Wayland (and failed) for even a tier-two platform, I can assure you that it’s a nightmare. Creating a new compositor would be a hellish experience. Ask any distribution packager who works with Wayland to share their horror stories — they have many.
The Wayland cargo cult needs to pause and re-evaluate. Switching to Wayland breaks things for anyone who steps even a toe out of the norm of GNOME/KDE/wlroots on Linux. Even on the supported platforms it comes with a substantial burden on build requirements, calling for 10× to 100× or more RAM, CPU time, and power usage. Whatever its benefits, choosing Wayland is ultimately choosing to lock a large group of people out of your project, and dooming many more to struggle and frustration. These are real trade-offs that you need to seriously consider.
Rewrite-it-in-Wayland has become a moral imperative. Well, here’s a moral argument: throwing away serviceable computers every couple of years to upgrade is a privilege that not all of your users have, contributes to climate change, and fills up landfills. As far as security is concerned, some matters demand leaving the norm: old hardware is the only kind that can avoid proprietary firmware blobs, Intel ME or AMD PSP, and UEFI. Novel hardware which addresses issues like microcode and open hardware, like POWER9 and RISC-V, are also suffering under Wayland’s mainstream-or-bust regime. Anyone left behind is forced to use the legacy Xorg codebase you’ve abandoned, which is much worse for their security than the hypothetical bugs you’re trying to save them from.
Xorg is not safe. It suffers from bad security. These are valid complaints. However, Xorg code can be secure! Just look at xscreensaver, which I guarantee you has fewer bugs than, say, gnome-screensaver. There are plenty of Xorg programs which aren’t formally verified that work fine, too. Rewriting your code in Wayland is always going to introduce new bugs, including security bugs, that wouldn’t be there if you just maintained the Xorg code. Maybe there are undiscovered bugs lurking in your Xorg codebase, but as your codebase ages under continuous maintenance, that number will only shrink.
A working Xorg toolchain (say, xcb) can be written in a couple tens of thousands of lines of code. The only working Wayland toolchain is tens of millions of lines of C code. How many undiscovered bugs do you think these two toolchains have when compared? How many of those are security issues? How much relative work would it be to debug them, or port them to new — or old — platforms? How often do these respective codebases churn, creating a larger maintenance burden and introducing new bugs/vulnerabilities? I can bootstrap a working Xorg toolchain in about 10 minutes. I spent a week trying to do that for Wayland, and failed. That matters.
Wayland is kind of cool, but it’s not a panacea. There are legitimate reasons to prefer Xorg, both technical and moral, and Wayland still needs a lot of work before it’s ready for the prime time in systems which prioritize stability, reliability, simplicity, and accessibility. Those of us who work with such systems, we feel like the Wayland community has put its thumbs into its collective ears, sung “la la la” to our problems, and proceeded to stomp all over the software ecosystem like a toddler playing “Godzilla” with their Lego, all the while yelling at us old fogies for being old and fogey.
To the Wayland team: it’s time to calm down. Slow down the protocol, write a specification, focus on improving your protocol extensions, support more Xorg programs, and work on performance, stability, and accessibility. Invest more in third-party implementations like wlroots. I spent almost a week, full-time, trying to bring up Wayland without a toolkit. The bootstrap process is absolutely miserable. Your ecosystem has real problems that affect real people. It’s time to stop ignoring them.