Frontmatter
| id | 9380 |
| title | [Epic] Resolve Grid Scroll Thrashing via E2E Benchmarking |
| state | Open |
| labels | epicaitestingperformance |
| assignees | tobiu |
| createdAt | Mar 7, 2026, 7:25 PM |
| updatedAt | Mar 7, 2026, 7:34 PM |
| githubUrl | https://github.com/neomjs/neo/issues/9380 |
| author | tobiu |
| commentsCount | 1 |
| parentIssue | null |
| subIssues | 9381 E2E: Create Deterministic Grid Thumb Drag Benchmark 9382 E2E: Implement Dynamic RTT Measurement for VDOM Updates 9383 E2E: Implement Predictive Delta Injection (Velocity & Acceleration) 9384 Implement generic Neo.util.Performance tracker 9385 E2E: Expose Performance tracker metrics via Remote Methods 9386 E2E: Add min velocity threshold to Grid Predictive Scrolling 9387 E2E: Implement Main Thread Optical Pinning for Grid Scrolling 9388 E2E: Enhance VDOM Update Pipeline with Meta Payload Support 9389 E2E: Remove Legacy Scroll Prediction Heuristics from Grid ScrollManager 9390 E2E: Fix GridRowScrollPinning Registration and DOM Lookup Flaws 9391 E2E: Refactor GridRowScrollPinning to Hybrid rAF Engine 9392 E2E: Implement GridRowScrollPinning Automated Test and Sync Refinement 9393 E2E: Implement GridRowScrollPinning via CSS Variables 9394 E2E: Validate GridRowScrollPinning against DevIndex Canvas Worker Latency 9395 E2E: Refine GridRowScrollPinning to Target Explicit Thumb Drags 9396 E2E: Implement Synthetic Thumb Drag Profiles for Optical Pinning Validation 9397 R&D: Explore "Fixed Glass Overlay" Strategy for Optical Pinning |
| subIssuesCompleted | 16 |
| subIssuesTotal | 17 |
| blockedBy | [] |
| blocking | [] |
[Epic] Resolve Grid Scroll Thrashing via E2E Benchmarking

Input from Gemini 3.1 Pro:
✦ Strategic Note for Implementation:
When addressing the "stale render" gap during high-velocity thumb drags, we should explore Predictive Row Range Calculation.
Rather than simply rendering the rows that match the current
scrollTop(which we know will be outdated by the time the VDOM arrives), theScrollManagercould calculate the current scroll velocity (px/ms).Using this velocity vector, it could predict where the
scrollTopwill be in ~32ms (an estimated round-trip time for the triangular worker pipeline) and instruct thegrid.Bodyto render that future row range instead.If successful, the VDOM payload will arrive just as the user's thumb reaches that exact point, eliminating the blank screen. The deterministic E2E Playwright tests will be essential for tuning this prediction algorithm.
The Problem: While
mousewheelscrolling performs smoothly, grabbing and rapidly dragging the custom vertical scrollbar thumb on a massive grid (e.g., 50k rows in DevIndex) results in prolonged periods of blank content and flickering upon release.Root Cause Hypothesis: The bottleneck is the triangular worker communication pipeline (App => VDom => Main => App). Even if this pipeline completes rapidly, a high-velocity thumb drag can move the scroll position hundreds of rows ahead during that window. When the VDOM payload arrives, it renders rows for a viewport the user has already left, resulting in a blank screen until the scroll stops and the pipeline catches up.
Context from Previous Session (Epic #9369): We recently implemented a granular, Set-based locking mechanism (
coordinatingNodes) inScrollSync.mjswith a 50ms debouncedsetTimeoutto prevent native event feedback loops. We need to investigate if this lock interacts poorly with the high-velocitysyncGridBodythrottle or the final VDOM paint.Strategic Goals for this Epic:
GridThumbDrag.spec.mjs).translate3d(x, Y, z)values from the currently mounted.neo-grid-rowDOM elements and compare them to the actualscrollTopof the.neo-grid-body-wrapper. A large discrepancy mathematically proves the "stale render" gap.bufferRowRangebased on active scroll velocity, ensuring the pipeline paints further ahead in the direction of the drag.ScrollSync50ms lock is artificially delaying the final "resting" VDOM payload paint upon thumb release.