Repository navigation
improve: reduce Cron search and rendering work - #189124
Merged
Merged
Conversation
Contributor
|
🦞👀 Pull request received. I will update this pull request when review starts. |
Contributor
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Contributor
Author
|
Merged via squash auto-merge.
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Nov 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What Problem This Solves
Large Cron lists spend substantial time constructing, focusing through, and removing decorative row markup, especially in WebKit.
Related: #189030, #189052.
User Impact
Cron search and row rendering do less work while keeping the existing controls, accessible names, keyboard focus, filtering, and menu placement. The WebKit/Chromium application-time target of ≤1.3× is not reached; the remaining measured gap is recorded below, not claimed as an irreducible floor.
Why This Change Was Made
Use the existing immutable mask renderer for the Run now and More glyphs. The 500-job fixture drops from 24,008 to 22,008 elements, without a new cache, state owner, dependency, or lazy import. Match the existing dimensions/stroke and use system ButtonText/GrayText in forced-color mode; the first visual diagnostic caught the mask background disappearing under forced colors.
Timeline/source-map inspection found native focus inside Menu's initial-focus callback dominates menu opening, native removal through Solid's keyed reconciler dominates filtering, and construction/insertion plus style recalculation dominates opening. Search retains the matching row; it does not rerender every retained row. Same-root menu positioning uses CSS anchors. The overlay-registry scan was small in these samples, so this PR does not rewrite its lifecycle or alter focus behavior.
Evidence
Acceptance recorded before measurement: production fixture, 500 jobs for search/menu and 50 for warm open; serial interleaved base/head/base A/A; both engines and viewports; native-input-to-last-DOM-commit application elapsed time. Ten pairs per search cell; twenty per open/menu cell after the first ten exposed noisy tails. No attributed >5% median regression or worse tail; >20% attributable regressions reject the change. Driver and settle are separate. WebKit CPUProfiler utilization is not used as CPU time.
Base:
a4b07c63b60cf3a971c824064c82946c530e1686. Same host, fixed production bundles. Headless only, synthetic Gateway; no live provider latency. Host load and A/A are retained with every observation.Values are application milliseconds (median/p95). Paired change compares head against the geometric mean of its two adjacent base observations. All 600/600 observations passed. One-minute host load ranged 13.7–35.2, median 22.0.
The noisy exceptions are explicit: Chromium menu raw medians rise about 1.1 ms desktop / 1.9 ms mobile; desktop p95 rises 8.2 ms. The unchanged desktop A/A p95 shifts 97.3 → 39.2 ms, and mobile A/A median drifts +5.3%. Under the prescribed noisy-host rule, twenty-pair Chromium script/task CPU and structure decide: desktop script 12.97 → 13.15 ms (paired −0.7%), task 118.75 → 113.16 ms (paired −2.8%); mobile script 12.54 → 12.84 ms (paired +0.4%), task 100.91 → 98.00 ms (paired −1.4%). No script/task CPU regression. WebKit desktop open is effectively flat: median +0.5 ms and p95 +2.2 ms across twenty pairs; no speedup claimed there.
Remaining head W/C application ratios: menu desktop/mobile 2.96× / 2.38×; search 2.48× / 2.72×; open 2.28× / 3.36×. The mobile-open ratio rises because Chromium gets faster; WebKit absolute time falls. These are an attributed remaining gap, not a claim of a universal floor.
Rerunnable workload:
node --import ./scripts/tsx.mjs scripts/bench-control-ui-engines.ts --bundle-dir <base-build> --compare-bundle-dir <head-build> --control-bundle-dir <base-build> --steps cron-menu-open,cron-search,cron-open --viewport both --engines chromium,webkit --pairs 10 --output <proof-dir>; the second ten pairs retain only open/menu. Separate source-mapped diagnostic runs use--trace.Timeline attribution
Two baseline WebKit traces per action/view, source-mapped, clipped to native input → last DOM commit. This is diagnostic elapsed time with trace overhead, not the untraced performance comparison. The table partitions overlaps in priority order paint/layout/style/script; composite envelopes are excluded. Script includes native browser work invoked by script. Uncovered time is not relabelled as script.
Final-head trace ranges (two per cell, all 12 passed), using the same disjoint partition:
Paint may land after the last DOM mutation and therefore outside this application window. The 69–129 ms traced desktop-search spread illustrates why these diagnostic runs are not used to infer the speedup. Final source maps again identify Menu initial focus (45/109 full-profile leaf samples) and keyed native removal (40 samples); sample counts are qualitative only.
Many WebKit sample timestamps are zero, so sample counts only identify likely call paths. Search's large native
selectsample count belongs to Playwright's pre-input driver preparation and is excluded from application attribution. The remaining ratio gap needs a further measured improvement in native focus/removal/style work; these traces do not establish that it is unavoidable.pnpm tsgo:uipassedpnpm deadcode:knippassed; no new ignoresProduction LOC across the three touched files: 1,797 → 1,808 (+15/−4). The growth is the required system-color CSS. No test LOC added. Solid refactor census: effects, render effects, untrack, listeners, DOM queries, flush, owner APIs, cleanup, controllers and manual loaders all remain 0 → 0 in the touched TSX files. The simplification reuses the existing glyph renderer; it introduces no abstraction.
Screenshots
Inspected synthetic WebKit menu captures, before/after at desktop and mobile. They preserve the existing appearance and geometry.