A Critique of GPUI
Native Rust GUI frameworks like GPUI and egui rely on state models that fail to scale efficiently for complex desktop applications due to a lack of fine-grained tracking.
read it The detailed architectural breakdown and performance benchmarks offer valuable insights into the trade-offs of different Rust UI state models.
summary
The author critiques the state models of popular native Rust UI frameworks—specifically GPUI, egui, and Iced—arguing that manual notification or full-frame re-renders fail to scale as application complexity grows. Using custom benchmarks, the post demonstrates how sparse state changes in large component trees trigger expensive tree walks or view re-renders unless mitigated with heavy boilerplate. It concludes that signal-based, run-once architectures offer superior performance for complex desktop applications, despite implementation trade-offs. However, critics note that the piece doubles as promotion for the author's own new framework, zgui.
key points
- GPUI relies on manual entity-level notifications, which causes full subtree re-renders when fields change unless manually optimized with caching boundaries.
- Immediate-mode frameworks like egui rebuild the entire UI every frame, hitting performance bottlenecks when scaling to thousands of elements.
- Signal-based, run-once architectures track reads automatically, avoiding manual invalidation boilerplate while scaling more gracefully for granular state updates.
who should read it
Rust developers and systems engineers building or evaluating native desktop graphical user interfaces.
discussion skeptical
consensus
Commenters are largely split, with many pushing back on the article's premise by noting that most real-world applications rarely hit these UI scaling limits in practice.
pushback
Some commenters argue that poorly performing UI architectures create hidden maintenance walls and that frameworks should be engineered to scale regardless of typical usage.
The central argument, reiterated countless times through the post is "It does not scale".
To which my reply is: "Who cares, the vast majority of apps do not have complex UIs".
And if they do you can come up with a workaround like e.g. rerun did for egui (outlined in the article).
Case in point: my biggest spare time "prompted" project is a now 500k LOC hybrid 3D modeling app. It uses egui.
I'd say modeling functionality-wise it's somewhere between Grasshopper/Houdini, close to 200 nodes out of the box + any number of custom ones
That gives you an idea about UI: node graph, parameter …
It provides a concrete counter-example from a 500k-LOC 3D modeling app running smoothly on egui without performance issues.
Generated by an LLM from the article and thread. Check the sources before relying on it.