-
Notifications
You must be signed in to change notification settings - Fork 1.9k
[Performance] Allow manual initialization of expensive operations to potentially decrease startup time #5248
Conversation
Nice! |
any updates? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, just a couple of questions and a typo.
Got the go ahead to check this in behind a PROFILE define. So I'll address the concerns, double check ensure everything is behind the PROFILE define, then get a final review, and merge it in... that's my plan. |
Eh, changed my plan. I'm not gonna hide behind a PROFILE. Instead, I'll add |
Build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm re-running the Fast Renderers tests. The other failing tests are not related to this PR.
184078f
to
bee5958
Compare
* man init * man init w/o profile * Update Xamarin.Forms.Platform.Android/Forms.cs Co-Authored-By: rmarinho <me@ruimarinho.net>
This reverts commit 0b69ead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Question about commented code.
@@ -127,7 +128,11 @@ protected void LoadApplication(Application application) | |||
|
|||
application.PropertyChanged += AppOnPropertyChanged; | |||
|
|||
//Profile.FramePartition(nameof(SetMainPage)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are all these Profile calls commented out?
* man init * man init w/o profile * Update Xamarin.Forms.Platform.Android/Forms.cs Co-Authored-By: rmarinho <me@ruimarinho.net>
This reverts commit 0b69ead.
To generate this profile you need to build a private nuget package with this branch and then build https://github.com/kingces95/droidperf.

Goal is to reduce startup time by making renderer registration explicit and allowing for feature opt out and to build in a profiler to allow adding regression tests.
NO BREAKING CHANGES -- All features are opt in: A new
Init
call + profiler logic lives behind a define.To generate the nuget:
To build the droidperf:
Profiler API:
The profiler API is built in but hidden behind a PROFILE define. The define is set in this branch to ease development. Will remove before accepting PR. To inject sampling points simply put:
Explicit Registration:
This is an example of using explicit renderer registration and optional opt-out of features.
Handlers
is an array ofExportRendererAttribute
Flags
is a list of features to opt out of usingTaken from: https://github.com/kingces95/droidperf/blob/23f8a333c08fd9f346ef3f4ef93ebfbbe68bc23a/XFMinUp/XFFastUp.Android/MainActivity.cs#L41