Skip to content

Batch action list width measurements#326642

Merged
ulugbekna merged 1 commit into
mainfrom
ulugbekna/batch-action-list-widths
Jul 21, 2026
Merged

Batch action list width measurements#326642
ulugbekna merged 1 commit into
mainfrom
ulugbekna/batch-action-list-widths

Conversation

@ulugbekna

Copy link
Copy Markdown
Contributor

Summary

  • batch action-list row width writes, geometry reads, and restores into three phases
  • preserve the row-to-item mapping used for toolbar-width accounting in visible and temporarily expanded hidden-item paths
  • add regression coverage for measurement ordering, toolbar accounting, and width restoration

Performance

Chromium CDP instrumentation over 49 representative rows and 200 measurement passes:

Implementation Layouts Style recalculations Duration
Alternating write/read/write 9,801 9,801 110.2 ms
Batched write/read/write 2 201 7.5 ms

Measured row widths were identical.

Validation

  • npm run typecheck-client -- --pretty false
  • ./scripts/test.sh --run src/vs/platform/actionWidget/test/browser/actionList.test.ts
  • npm run valid-layers-check
  • npm run precommit

Fixes #326640

cc @sandy081

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 0c897748-1cc7-4982-afbd-13377eb136a5
Copilot AI review requested due to automatic review settings July 20, 2026 15:42

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Batches action-list width measurements to reduce layout thrashing while preserving toolbar accounting and row styles.

Changes:

  • Groups width writes, geometry reads, and restoration into phases.
  • Adds regression coverage for ordering, toolbar width, and restoration.
Show a summary per file
File Description
actionList.ts Adds batched row-width measurement helper.
actionList.test.ts Tests batching and width calculations.

Review details

  • Files reviewed: 2/2 changed files
  • Comments generated: 0
  • Review effort level: Medium

@ulugbekna

Copy link
Copy Markdown
Contributor Author

@sandy081 merging to get more selfhosting time in. We can revert if you don't like the change when you're back

@ulugbekna
ulugbekna merged commit d1bc5c3 into main Jul 21, 2026
30 checks passed
@ulugbekna
ulugbekna deleted the ulugbekna/batch-action-list-widths branch July 21, 2026 13:06
@vs-code-engineering vs-code-engineering Bot added this to the 1.131.0 milestone Jul 21, 2026
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.

Action widget width measurement forces layout per row

3 participants