atriumatrium

Diagnostics & performance

Performance Bundle, Rust flame graphs, the Performance HUD, and Safari Web Inspector access.

When atrium feels slow or you want to file a bug with reproducible evidence, the Settings → Diagnostics panel collects everything needed to investigate without you reaching for samply, pprof, or DevTools by hand. The same surface drives the in-app Performance HUD and the gated Safari Web Inspector.

The underlying instrumentation (long-task observer, render stats, IPC timings, terminal stats, memory stats) is off by default — flip the toggles under Settings → Diagnostics to opt in. See config.diagnostics for the JSON shape.

Performance Bundle

The Performance Bundle is a one-click capture that records a flame graph, a stats snapshot, and the recent diagnostics traces into a single archive — the same evidence we ask for in slowdown reports.

  • Start from Settings → Diagnostics → Performance Bundle → Start capture.
  • Duration — captures can run up to 10 minutes. The capture state survives closing and reopening the Settings dialog, so you can drive the app normally during the recording.
  • Notification — a system notification fires when the bundle is ready, with a button to reveal it in Finder.
What's inside:
  • A samply-style flame graph for the Rust side (see Rust flame graph).
  • Diagnostics traces from any instrumentation toggles you have on — long tasks, render stats, IPC timings, terminal throughput, memory.
  • A stats.json rollup describing the app at capture time: workspaces, panes, adapter sessions, build channel, OS, locale.
  • Outbound telemetry payloads (so you can verify what left the app during the recording).
The bundle does not include workspace contents, scrollback, editor buffers, or agent transcripts. Inspect it before sharing — it's a zip you can open and audit.

Rust flame graph

For a quick Rust-side capture without the full bundle, use Settings → Diagnostics → Rust flame graph → Capture. atrium runs pprof-rs in-process and writes a protobuf flame graph plus a symbol directory, so you can analyze the result post-hoc with any pprof-compatible tool (go tool pprof, Speedscope, samply).

The capture writes to ~/.atrium/diagnostics/flamegraph-*/:

  • profile.pb.gz — pprof protobuf.
  • symbols/ — symbol directory so the flame graph reads cleanly off-line.
The capture is short by default (a few seconds); start it just before reproducing the slowdown and stop it as soon as the slow path completes.

Performance HUD

The title-bar HUD is a live readout you can leave on while working. Toggle it from Settings → Diagnostics → Performance HUD.

It surfaces:

  • FPS — frames per second, sampled per second.
  • Frame lag — worst frame time over the last second.
  • IPC throughput — Tauri commands per second, plus a peak.
  • Pane count — total mounted panes (across all rooms in the active workspace).
The HUD is intentionally cheap — it adds a handful of microseconds per frame to read instrumentation counters. Useful for sizing up "is this view heavy" without firing a full capture.

Safari Web Inspector

For frontend debugging atrium ships a gated Safari Web Inspector hook. Enable it under Settings → Diagnostics → Allow Safari Web Inspector; relaunch is required (atrium prompts you). The flag is off by default so production builds can't be probed without explicit opt-in.

Once enabled, attach Safari's Develop menu to the atrium process the same way you would for any WKWebView app. The inspector lets you walk the React tree, evaluate JS, and look at network requests against the local IPC bridge.

Where the data lives

  • Diagnostics traces and flame graphs — ~/.atrium/diagnostics/.
  • Performance bundles — also ~/.atrium/diagnostics/, named bundle-*.zip.
  • Live HUD counters — in memory only; not persisted.
The diagnostics directory is the safe-to-share part of ~/.atrium/. Nothing in it includes file contents, agent transcripts, or scrollback unless you explicitly tick a toggle that would (none are on by default).

Privacy

Diagnostics opt-in is separate from telemetry. Captures and bundles stay on disk until you share them; nothing is uploaded automatically. See Telemetry for the always-/opt-in event stream that does leave the machine, including the inspector this skill uses to verify no regressions leak data.