Improve measure invalidation and legacy Layout(s) performance #24551
Labels
area-layout
StackLayout, GridLayout, ContentView, AbsoluteLayout, FlexLayout, ContentPresenter
s/triaged
Issue has been reviewed
Milestone
TL;DR
MeasureInvalidated
on scrollable views and pagesDescription of Change
I executed a speedscope.zip on davidortinau/AllTheLists
LearningPage
using the latest8.0.90-ci.net8.24430.1
build.What I noticed is that #23052
OnChildMeasureInvalidatedInternal
was showing up and taking 2% of total time (recursive calls).This revealed an interesting thing, the time consumed in there is only due to legacy layouts (which includes
ContentView
) which are triggering synchronous native measurements instead of waiting for the layout pass which is optimized as it runs only once for each invalidated view.Therefore I realized al that code is actually not needed and substantially wrong.
After these changes, the speedscope looks like this:
As you can see, legacy layout calls and page calls are gone, except for the
TemplatedCell
of the collection view which is still triggering synchronous measurements.The text was updated successfully, but these errors were encountered: