Skip to content

perf(render): cache stable ray proxy identities#117

Merged
Arbousier1 merged 3 commits into
devfrom
codex/perf-ray-proxy-stable-plan
Jul 20, 2026
Merged

perf(render): cache stable ray proxy identities#117
Arbousier1 merged 3 commits into
devfrom
codex/perf-ray-proxy-stable-plan

Conversation

@Arbousier1

@Arbousier1 Arbousier1 commented Jul 19, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • let unchanged active viewers reuse their stored Player without repeating session.onlinePlayer(viewerId)
  • resolve a fresh session Player only when no active proxy exists, geometry/ownership changed, or the cached Player is offline
  • preserve the original coordinator, proxy record, registry and allocation-sensitive object layouts
  • add regression coverage proving unchanged regions perform one viewer lookup while reconnects switch to a fresh Player

Performance

Latest local protected-profile smoke comparison against origin/dev:

  • 1 viewer: 407.2 ns/op -> 326.4 ns/op (~19.8% lower)
  • 4 viewers: 963.9 ns/op -> 868.5 ns/op (~9.9% lower)
  • 32 viewers: 5209.7 ns/op -> 4884.3 ns/op (~6.2% lower)
  • 1-viewer allocation: 2312 B/op -> 2224 B/op (~3.8% lower)
  • 4-viewer allocation: 5536 B/op -> 5568 B/op (~0.6% increase)
  • 32-viewer allocation: 31400 B/op -> 31376 B/op (flat/slightly lower)

Two earlier protected runs exposed escape-analysis regressions from added cache fields. Commit ef9ec5e removes all layout-changing caches and leaves only the viewer-lookup fast path.

Test plan

  • SparrowRayInteractionProxyCoordinatorTest
  • unchanged-region viewer lookup count
  • offline cached viewer reconnect coverage
  • null-session TableRegionKeyCacheTest compatibility
  • spotlessCheck
  • full check assemble (709 tests, 7 skipped)
  • local RayProxyCoordinatorBenchmark smoke A/B
  • protected ray-proxy paired A/B gate for ef9ec5e
  • Linux, Windows, and macOS CI for ef9ec5e

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@Arbousier1 Arbousier1 added performance-ab Run the base-owned paired performance gate performance-ray-proxy Use the client ray-proxy performance profile labels Jul 19, 2026
@Arbousier1 Arbousier1 added performance-ab Run the base-owned paired performance gate and removed performance-ab Run the base-owned paired performance gate labels Jul 20, 2026
@Arbousier1
Arbousier1 merged commit 8456926 into dev Jul 20, 2026
29 of 33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

performance-ab Run the base-owned paired performance gate performance-ray-proxy Use the client ray-proxy performance profile

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant