Two months ago I posted here about running rustc, cargo and lld as WebAssembly on an iPad. I said I had no rust-analyzer: I had compiled it to wasm and measured it, and the proc-macro and std source costs looked too high for a tablet. It's in the app now, with a catch: it only runs when the device has the memory for it. The editor is also native now; it was Monaco in a web view then.
The screenshot is the editor with the debugger paused at a breakpoint.
What I use rust-analyzer for first is color.
Before rust-analyzer is warm, the editor is colored by a tree-sitter highlighter, and the status line says "basic colours". When rust-analyzer finishes indexing, its semantic tokens replace those colors. Both servers are translated into one vocabulary, so a word whose category doesn't change keeps its color. What rust-analyzer adds is the distinctions a grammar can't make: a trait versus a struct versus an enum versus a type alias, a method versus a free function, a macro_rules macro versus a proc-macro, value parameters, lifetimes, Self, the mutable modifier, items from a dependency crate, and unresolved references.
The memory rule, since that's the interesting part. The default is "Auto":
- device with 6 GB or more: full rust-analyzer when there is headroom, otherwise a reduced mode
- device with 4 to 6 GB: the reduced mode when there is headroom, otherwise off
- device with under 4 GB: off
"Headroom" means no memory-pressure warning and more than 2000 MB available. Pressure steps the level down one notch, and a warning expires after 45 seconds of quiet. During a build, if available memory drops below 2000 MB, rust-analyzer is released so rustc has the memory, and in Auto it comes back when the build ends (it retries every 5 seconds for about two minutes). If rust-analyzer fails to start, it is retried after 5, 20 and 60 seconds. You can also force it on, off, or to the reduced mode in settings.
The reduced mode drops the Cargo dependency graph, the crate index and code lens, the chaining, closure and borrow hints (type and parameter hints stay), and files over 200 KB. The cost is real: without the graph, crates show up as "missing reference". The graph itself needs a device with at least 7000 MB and at least 3000 MB available, and the editor doesn't attempt one for projects over 120 crates. Proc-macros only expand when a compiled reactor for that crate is already cached, otherwise the crate stays unexpanded for that graph load.
Numbers, with a caveat: I don't have an on-device warm-up time I trust yet. These are from running the same wasm under Node on a Mac:
- warm-up in a single-file project: 1.3 to 2.7 s, heap about 220 MB
- a small project with a couple of crates: about 300 MB, 1.9 to 2.2 s
- a project with 93 crates: about 500 MB, 3.4 s (about 3 MB per crate)
- semantic tokens for a 3,100-line file: 128 to 213 ms cold, 36 to 53 ms warm
- the rust-analyzer wasm is about 16 MB, built from the 2026-08-31 tag with Rust 1.98.0 for wasm32-wasip1, optimized with wasm-opt -O3
I also added GitHub Copilot after people asked for it in that thread. It uses your own subscription.
Same disclosure as before: it's a paid, closed-source app with a free tier for single files, I'm the author, and it's in TestFlight beta: https://testflight.apple.com/join/4Yaujqd5
I'd like to know where it falls over: crates that fail to build, rust-analyzer colors or diagnostics that differ from a desktop, and any device where the memory rule picks the wrong level. I'll be traveling for most of November, so replies may be slow.