Skip to content

bench(reactive): measure retained component handles - #117

Draft
1bye wants to merge 1 commit into
mainfrom
feat/reactive-redraw-108
Draft

1bye wants to merge 1 commit into
mainfrom
feat/reactive-redraw-108

Conversation

@1bye

@1bye 1bye commented Nov 29, 2026

Copy link
Copy Markdown
Owner

Refs #108

Summary

  • Added a benchmark-only retained-handle variant for experimental function components.
  • Extended the headless benchmark with bulk-redraw, measuring the 10,000-row signal update and the immediately following parent redraw in one run.
  • Reported process-CPU p50/p95 and allocation counts from six order-rotated repetitions in .agents/reports/reactive-signals.md.
  • Kept the runtime unchanged: retained handles improve the parent redraw and remove one allocation per row, but the matched bulk workload still misses the ~10% overhead target.

Results

Bulk update, uncached:

Implementation p50 CPU p95 CPU Allocations/update
Plain GPUI 46.54 ms 51.20 ms 130,052
Stock Rake 64.31 ms 66.74 ms 140,052
Retained handles 56.68 ms 59.78 ms 130,052

Following parent redraw, uncached:

Implementation p50 CPU p95 CPU Allocations/redraw
Plain GPUI 48.55 ms 53.52 ms 130,044
Stock Rake 55.23 ms 57.95 ms 140,044
Retained handles 49.64 ms 56.07 ms 130,044

Verification

  • target/debug/rake format
  • target/debug/rake lint
  • target/debug/rake lint --deep
  • cargo test -p rake-app --locked --features experimental-reactive,view-test-support --lib --test function_components --test view --test view_components --test view_state
  • Final benchmark smoke run for --headless retained bulk-redraw 10 1

The benchmark asserted one host render per update/redraw, all 10,000 updated row values, stale-write failure after unmount, and zero runtime component/signal/observer/subscription/task counts after disposal.

Co-Authored-By: SWE-2.1 via Devin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant