LearnNewsExamplesServices
Frontmatter
id9203
titleInvestigate Grid Scrolling Performance via Column Ablation Strategy
stateClosed
labels
aitestingperformance
assigneestobiu
createdAtFeb 18, 2026, 1:07 PM
updatedAtFeb 18, 2026, 2:11 PM
githubUrlhttps://github.com/neomjs/neo/issues/9203
authortobiu
commentsCount3
parentIssue9194
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtFeb 18, 2026, 2:11 PM

Investigate Grid Scrolling Performance via Column Ablation Strategy

Closed v12.0.0 aitestingperformance
tobiu
tobiu commented on Feb 18, 2026, 1:07 PM

Recent benchmarks (#9199) identified a significant performance bottleneck in the Grid component on Desktop viewports (1920x1080).

  • Mobile (375x667): 60 FPS
  • Laptop (1366x768): 54 FPS
  • Desktop (1920x1080): 30 FPS

The sharp drop to 30 FPS on Desktop, despite only a ~12% increase in active cells compared to Laptop, suggests a non-linear scaling issue or a specific CSS/Layout trigger that is disproportionately expensive at this scale.

Since general optimizations (throttling, buffer reduction) failed to improve the Desktop framerate, we need to isolate the specific rendering cost.

Strategy: Column Ablation We need to systematically remove specific column types from the DevIndex grid and re-run the benchmark to identify if a particular component style is the culprit.

Tasks:

  1. Modify Benchmark: Update test/playwright/e2e/GridScrollBenchmark.spec.mjs to support an excludeColumn parameter (or create variants).
  2. Test Iterations: Run the benchmark on Desktop (1920x1080) for each scenario:
    • Baseline: All columns active (Control).
    • No Images: Exclude GitHubOrgs, CountryFlag, and IconLink (Avatar/Flag/Icon images).
    • No Sparklines: Already tested (30 -> 33 FPS, minor impact), but worth re-verifying in this suite.
    • No Custom Components: Exclude Heuristics.
    • Text Only: Hide all Year/Number columns (reduce text node count).
  3. Analyze: Compare the FPS and Main Thread Trace activity.
    • If removing CountryFlag jumps FPS to 50+, investigate its shadow/border/SVG styles.
    • If removing GitHubOrgs jumps FPS, investigate border-radius or image decoding costs.
    • If "Text Only" is still slow, the issue is the raw layout cost of the CSS Grid/Flexbox structure itself.

Outcome: Identify the specific CSS/DOM feature causing the 30 FPS cap on large screens.

tobiu added the ai label on Feb 18, 2026, 1:07 PM
tobiu added the testing label on Feb 18, 2026, 1:07 PM
tobiu added the performance label on Feb 18, 2026, 1:07 PM
tobiu assigned to @tobiu on Feb 18, 2026, 1:08 PM
tobiu added parent issue #9194 on Feb 18, 2026, 1:08 PM
tobiu
tobiu Feb 18, 2026, 1:11 PM

Input from Gemini 3 Pro:

Additional Hypothesis: The Desktop bottleneck might be caused by the Heatmap Text Shadows (text-shadow in resources/scss/src/apps/devindex/home/GridContainer.scss).

&.heatmap-cell-3 {
    text-shadow: var(--heatmap-shadow-3);
}

On smaller viewports (Mobile/Laptop), these year columns might be hidden or fewer are visible. On Desktop (1920px), all ~15 year columns are visible. Rendering 15 columns x 29 rows = 435 text shadows per frame could be the compositing killer.

Investigation: Add a test case to the Column Ablation suite to specifically disable text-shadow on heatmap cells.

tobiu
tobiu Feb 18, 2026, 2:03 PM

Input from Gemini 3 Pro:

✦ I have completed the Column Ablation investigation for the Desktop (1920x1080) performance bottleneck.

Methodology

I systematically modified the GridContainer and SCSS to isolate specific rendering costs, running the GridScrollBenchmark for each scenario on the Desktop viewport.

Results

Scenario Description DOM Nodes Horizontal FPS Vertical FPS Status
Baseline All columns & styles active ~2,285 30-32 30 🔴
No Text Shadow CSS text-shadow: none on heatmap ~2,285 33 32 🔴
No Sparklines Removed activity column ~2,285 33 32 🔴
No Images Removed Avatar, Flags, Icons (User, Repo, etc.) 1,329 33 30 🔴
Text Only Removed Images + Year Columns (Reduced Grid Size) 2,090 34 30 🔴
No Cell Styling CSS background: transparent; border: none on ALL cells ~2,285 32 30 🔴

(Note: "Text Only" node count was higher than "No Images" because it retained the Sparkline canvas and other heavy components, only hiding the years/images loop.)

Key Findings

  1. Rendering is NOT the Bottleneck: Even stripping all cell styling (making the grid invisible) or removing all images did not improve the frame rate. The GPU/Compositor is not saturated.
  2. Node Count is NOT the Sole Factor: Reducing the DOM node count by ~40% (No Images scenario) had zero impact on FPS.
  3. Linear Scaling Limit:
    • Mobile: ~300 active cells -> 60 FPS
    • Desktop: ~560 active cells -> 30 FPS
    • The performance degrades linearly with the number of managed cells. 2x cells = 0.5x FPS.

Conclusion

The 30 FPS cap on Desktop is caused by the Main Thread Scripting or VDOM Diffing/Patching overhead associated with managing ~600 reactive cell components. The browser simply cannot process the VDOM updates and DOM patches for this many elements within the 16ms frame budget, regardless of how simple the elements are.

Next Steps

Optimization must focus on reducing the frequency or cost of VDOM updates, rather than CSS/Rendering optimizations.

  • Throttle Scroll Updates: Ensure scroll events are not triggering VDOM updates faster than the engine can handle.
  • Static VNodes: Identify if static cell parts can be optimized to skip diffing.
  • CSS Grid vs Flexbox: Investigate if the layout engine itself is thrashing due to Flexbox nesting depth.
tobiu
tobiu Feb 18, 2026, 2:10 PM

Input from Gemini 3 Pro:

✦ Investigation complete. The "Column Ablation" strategy confirmed that the performance bottleneck is not caused by specific CSS styles (text-shadows), heavy components (sparklines, images), or DOM node count alone. The issue is a linear scaling limit of the VDOM diffing/patching mechanism when managing ~600+ reactive cells on large viewports.

Closing this investigation ticket. Future work will focus on VDOM optimization strategies (throttling, static VNodes, layout optimizations).

tobiu closed this issue on Feb 18, 2026, 2:11 PM
tobiu cross-referenced by #9204 on Feb 18, 2026, 2:12 PM