Skip to content

Fixes #5335. Correct TableView benchmark baselines and per-method IterationSetup#5348

Merged
tig merged 1 commit into
developfrom
tig/fix-tableview-benchmark-baseline
May 19, 2026
Merged

Fixes #5335. Correct TableView benchmark baselines and per-method IterationSetup#5348
tig merged 1 commit into
developfrom
tig/fix-tableview-benchmark-baseline

Conversation

@tig
Copy link
Copy Markdown
Member

@tig tig commented May 19, 2026

Summary

Fixes the false performance gate regression reported in #5335 by correcting invalid baseline values and improving benchmark accuracy.

Changes

Tests/Benchmarks/baseline.json

  • Corrected PageDown_OneStep baselines from ~20 ms → ~53 ms (matching ScrollDown_OneStep, since both call LayoutAndDraw() and rendering cost dominates)
  • Added missing ScrollUp_OneStep and ScrollRight_OneStep entries (both ~53 ms)
  • Updated _comment documenting the correction

Tests/Benchmarks/Scrolling/TableViewScrollBenchmark.cs

  • Replaced single [IterationSetup] with targeted per-method setups:
    • IterationSetup_ScrollDown (targets ScrollDown, PageDown, ScrollRight): selection at last visible row
    • IterationSetup_ScrollUp: selection at first visible row with RowOffset at mid-table so up-arrow triggers actual scrolling

Root Cause

The original PageDown baseline (~20 ms) was captured under conditions that didn't match the actual benchmark behavior. Since all scroll benchmarks execute _app.LayoutAndDraw() (full redraw), they should have similar baselines. The ~20 ms value caused 3.5× false regression flags on PRs.

Verification

  • dotnet build Tests/Benchmarks -c Release passes

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6fc50e0519

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Tests/Benchmarks/Scrolling/TableViewScrollBenchmark.cs Outdated
Copilot finished work on behalf of tig May 19, 2026 14:37
@tig tig force-pushed the tig/fix-tableview-benchmark-baseline branch from 6fc50e0 to ca9db8c Compare May 19, 2026 14:47
…rationSetup

- Update PageDown_OneStep baselines from ~20ms to ~53ms (matching
  ScrollDown_OneStep, since both call LayoutAndDraw)
- Add missing ScrollUp_OneStep and ScrollRight_OneStep baseline entries
- Replace single IterationSetup with targeted setups: ScrollUp starts
  at the first visible row with RowOffset > 0, ScrollRight starts at
  the last visible column boundary
- Widen cell data to 14+ chars so 10 columns overflow the 120-cell
  viewport, ensuring CursorRight actually triggers horizontal scrolling

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
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