
Image: InfoQ
Why it mattersA large consumer app is showing numbers for a Rust rewrite. A product team can now point at real figures when their Electron app feels slow.
Discord's app feels slow because a Chromium browser is sitting under every window. The company is betting that a GPU-drawn Rust client can fix that.
Stanislav Vishnevskiy, Discord's CTO, said on X that Discord is rewriting its desktop and mobile clients in Rust. The internal name is Phoenix. The desktop app drops Electron for GPUI. GPUI is the Rust UI framework the Zed team built for the Zed code editor. The mobile app drops React Native. It uses native iOS and Android views instead. A Rust core is shared with the desktop build. The browser client stays on HTML, with the app logic compiled to WebAssembly.
Vishnevskiy posted early measurements. On desktop, an internal build runs at about 290 MB of RAM with two accounts signed in. The current Electron app takes 5.5 seconds to cold-start. On mobile, the new app loads in under 2 seconds. The old one takes about 5 seconds. He wrote that clicking around "feels instant" and said he cannot go back. InfoQ carried the story and says Discord has been using Rust in its infrastructure and voice work since 2018.
What GPUI gives up
GPUI replaces the browser engine with a hybrid immediate and retained mode renderer. It targets 120 frames per second. It avoids pauses from a garbage collector. The trade-off is that features a browser gives you for free are no longer there. Text layout is one. Input method integration for languages like Japanese and Chinese is another. Screen reader hooks and right-to-left text are the others. InfoQ says Rust libraries exist for some of these, including Parley for text layout. A team using GPUI still has to wire each one in by hand.
That is the cost of leaving Electron. Zed's own argument, which InfoQ quotes, is that VS Code won by being good enough for everyone. Zed wins by being excellent for developers who will not trade speed for anything. Discord is making the same bet for a consumer app with hundreds of millions of users.
Mobile is a separate bet
Discord's mobile rewrite tests a different idea. The idea is that React Native's new architecture still trails native. Elias Floreteng's KTH master's thesis compared native Swift and Kotlin against React Native. The test was a 1,000-row image list with the same assets. The thesis found Swift ahead across every runtime metric on iOS. On Android the gap was smaller and ran both ways, with native ahead on memory and CPU.
Discord's answer is to write the UI twice, in Swift and Kotlin. Only the app logic is shared through Rust. Vishnevskiy addressed this on X: the project uses GPUI on desktop and native views on mobile, with Rust shared underneath.
A product team running an Electron desktop app can now point at Discord's numbers. The headline figure is a 5.5 second cold start against near-zero on the GPUI build. The two measurements are on the same app.
Source
- Stanislav Vishnevskiy on X, the rewrite thread and the follow-up on GPUI versus Tauri.
- InfoQ, Discord Rewrites Desktop and Mobile Clients in Rust Using Zed's GPU-Accelerated Rendering Framework, by Bruno Couriol.
This item was written by an AI system from the linked source. Reveneau is responsible for what it publishes.
Get AI News in your inbox
New developer tools, model and agent releases, and how teams are actually using them to release software. Short, and only when there is something worth reading.