Measure invalidation performance and fixes#24532
Closed
albyrock87 wants to merge 16 commits into
Closed
Conversation
ca4b0a7 to
5b65d84
Compare
|
@albyrock87 I'm quite interested on your phrase: " due to legacy layouts (which includes ContentView)" , the example has a CollectionView with a DataTemplate , that has a ContentView as a parent - should we have better performance, in having for instance, DataTemplates with a Grid / Border as a parent? |
Member
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
5b65d84 to
2d0c694
Compare
Contributor
Author
|
@bcaceiro after this PR it shouldn't matter if you use ContentView or not. |
f5239da to
b2874d6
Compare
albyrock87
commented
Sep 6, 2024
| var request = new Size(size.Request.Width + Padding.HorizontalThickness, size.Request.Height + Padding.VerticalThickness); | ||
| var minimum = new Size(size.Minimum.Width + Padding.HorizontalThickness, size.Minimum.Height + Padding.VerticalThickness); | ||
|
|
||
| DesiredSize = request; |
Contributor
Author
There was a problem hiding this comment.
Base method sets DesiredSize so the fact this was missing was simply wrong.
albyrock87
commented
Sep 6, 2024
Member
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
b2874d6 to
a8780b1
Compare
Member
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
a8780b1 to
3153543
Compare
Member
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
Member
|
/azp run |
- Do not bubble up `MeasureInvalidated` on pages - Invoke `MeasureInvalidated` just once when `BindingContext` is changing - Do not synchronously measure/arrange children on legacy layout upon child measure invalidated: simply wait for the next native layout pass
… switch branches
…parent correctly
…e to invalidate parent chain through the platform view on `ScrollView` (iOS)
2628e98 to
b9e69c7
Compare
Member
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
Member
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
Contributor
Author
|
Closing in favor of #25664 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of Change
Initial proposal to solve #24551 .
I executed a speedscope on davidortinau/AllTheLists
LearningPageusing the latest nightly8.0.99-ci.net8.24468.1build.What I noticed is that #23052
OnChildMeasureInvalidatedInternalwas showing up and taking 2% of total time (recursive calls).What I've done:
Handler = null)SetNeedsLayoutpropagation issues and cleans up detection of autoSetNeedsLayoutparent propagation withIPropagatesSetNeedsLayoutinternal interfaceWinUI Speedscope
Kindly provided by @MartyIX
Before

main1726819823.MAIN.speedscope.json
After

PR1726819948.PR.speedscope.json
Before

main1726819865.MAIN.speedscope.json
After

PR1726819973.PR.speedscope.json
iOS Speedscope
Before

mainbefore.speedscope.json.zip
After

PRafter.speedscope.json.zip
Issues Fixed
Fixes #24551