Skip to content

perf: performance plan for the macOS app, the core and the drivers #4559

Backlog

Description

@datlechin

Plan from a measured pass over the macOS app, the Rust core and the drivers: Instruments traces, heap and footprint readings, server statement logs, and a code review where each finding was checked a second time. Every item fixes the cause the measurement or the code path shows. No special cases and no caps that hide a cost.

Where the time and memory go

  • Results are rows of enums: a 24-byte value per cell, a heap string per text over 15 bytes, a heap array per row. 1M x 20 is 1.26 GB on PostgreSQL and 856 MB on MySQL.
  • The UI around the data costs more than the data. Opening a table spends about 167 ms of main-thread CPU, 75% of it SwiftUI; the driver fetch is 5 to 15 ms. Typing spends about 12.7 ms of main-thread CPU per key.
  • Connecting opens 3 PostgreSQL connections and sends about 19 statements to open one table, with the table, database and schema lists each read twice.
  • Drivers convert values several times, and nothing bounds memory across a long session.

Decisions

  • The result data path moves onto the core now: one columnar store for macOS, Windows and Linux. This changes the order in ADR 0010, which gets an amendment first.
  • The macOS 13 floor stays. Per-tab invalidation is built by hand with ObservableObject.
  • No app-imposed row limit. The row limit stays a user setting, and the 5,000,000-row emergency cap goes once the store lands.

Result data path

Main thread and view architecture

SQL editor

Autocomplete

Connecting and round trips

Drivers

Import and export

Long sessions

Related open items from the earlier audit: #4436 #4437 #4438 #4439 #4442 #4444 #4453 #4454 #4459 #4462 #4464.

Activity

  1. added
    enhancement
    platform-macos
    rust
    on Nov 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementplatform-macosrust

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions