Performance review of the whole codebase #230

Closed
opened 2026-10-21 19:05:08 +00:00 by littlefox · 1 comment
Owner

User, 2026-10-21 (D-058): "When you're done with the issues I gave you. I want you to also make a general investigation into the codebase and see where we can get improvements in performance and resource usage. Things are relatively heavy as they are now"

After #225–#229: go through the client library, the app, the relay and the build (binary and wasm size, startup, idle CPU, network round trips, allocations, the web image). File what is worth doing as separate issues in 0.6, with the measured or estimated gain.

User, 2026-10-21 (D-058): "When you're done with the issues I gave you. I want you to also make a general investigation into the codebase and see where we can get improvements in performance and resource usage. Things are relatively heavy as they are now" After #225–#229: go through the client library, the app, the relay and the build (binary and wasm size, startup, idle CPU, network round trips, allocations, the web image). File what is worth doing as separate issues in 0.6, with the measured or estimated gain.
Author
Owner

Review done; what it found is filed in 0.6:

  • #231 web download: 4.5 MB of wasm, 1.3 MB of it debug info, and no release profile;
  • #232 local search index: up to ~80 MB in memory; on desktop the whole file is rewritten per post once full;
  • #233 idle cost: the 250 ms seen-poll, a 30 s clock that redraws whole threads, presence that redraws every dot;
  • #234 server round trips: cards loaded one by one, previews fetch a stat for every reply, one mark-as-read per text, copies on hot paths;
  • added to #226 (props cloned and compared in full), #227 (pictures re-encoded as base64 on every render, held twice), #228.
    Checked and fine as they are: Caddy compresses (zstd/gzip) and caches the hashed assets forever; the protocol decoder scans incrementally; the relay forwards bytes without parsing; the keepalive interval.
Review done; what it found is filed in 0.6: - #231 web download: 4.5 MB of wasm, 1.3 MB of it debug info, and no release profile; - #232 local search index: up to ~80 MB in memory; on desktop the whole file is rewritten per post once full; - #233 idle cost: the 250 ms seen-poll, a 30 s clock that redraws whole threads, presence that redraws every dot; - #234 server round trips: cards loaded one by one, previews fetch a stat for every reply, one mark-as-read per text, copies on hot paths; - added to #226 (props cloned and compared in full), #227 (pictures re-encoded as base64 on every render, held twice), #228. Checked and fine as they are: Caddy compresses (zstd/gzip) and caches the hashed assets forever; the protocol decoder scans incrementally; the relay forwards bytes without parsing; the keepalive interval.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
littlefox/neokom#230
No description provided.