A deep dive into optimizing a browser-based spreadsheet engine by reducing the fixed cost of cell recalculation. The bottleneck was a method called `_makeCalcCellEvaluationContext` consuming 12.5% of recalculation time by eagerly constructing a large evaluation context object for every cell. The fix involved two techniques:
Table of contents
GRID’s Spreadsheet EngineThe cost of recalculationEvaluating the fixed costEliminating the fixed costEvaluating the impactConclusionSort: