Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Shell] Rework the Shell route parsing code so it performs better #4888

Open
PureWeen opened this issue Feb 24, 2022 · 3 comments
Open

[Shell] Rework the Shell route parsing code so it performs better #4888

PureWeen opened this issue Feb 24, 2022 · 3 comments
Assignees
Labels
area-controls-shell Shell Navigation, Routes, Tabs, Flyout t/perf The issue affects performance (runtime speed, memory usage, startup time, etc.) (sub: perf) Task neither bug nor feature but something that needs to be done in support of either
Milestone

Comments

@PureWeen
Copy link
Member

Currently the code that parses a shell route does a lot of conversion between URI and Strings and string parsing. This is causing a measurable impact on startup performance when using even the most basic Shell App.

@PureWeen PureWeen added legacy-area-perf Startup / Runtime performance area-controls-shell Shell Navigation, Routes, Tabs, Flyout labels Feb 24, 2022
@jonathanpeppers
Copy link
Member

Here is a speedscope of the Podcast app:

dotnet-podcasts.zip

If you look for MobileShell.InitializeComponent() some of the methods are:

image

And also:

image

(so some of the StartsWith calls are culture aware)

I think this is the methods in this class:

https://github.com/dotnet/maui/blob/main/src/Controls/src/Core/Shell/ShellUriHandler.cs

If this code could create one Uri per call or none, and not string.Split() and string.Join() as much, we'd be there.

@jonathanpeppers
Copy link
Member

I think some of this was improved by #4988 and #5262.

Trying latest maui/main, I see more like:

image

image

image

Speedscope files: dotnet-podcasts.zip

@PureWeen PureWeen removed their assignment Aug 3, 2022
@jonathanpeppers jonathanpeppers moved this from Todo: Performance to Future: Performance in .NET 7 MAUI Performance Aug 18, 2022
@PureWeen PureWeen modified the milestones: .NET 7 + Servicing, Backlog Aug 29, 2022
@ghost
Copy link

ghost commented Aug 29, 2022

We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process.

@samhouts samhouts added the Task neither bug nor feature but something that needs to be done in support of either label Jul 31, 2023
@Eilon Eilon added t/perf The issue affects performance (runtime speed, memory usage, startup time, etc.) (sub: perf) and removed legacy-area-perf Startup / Runtime performance labels May 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-controls-shell Shell Navigation, Routes, Tabs, Flyout t/perf The issue affects performance (runtime speed, memory usage, startup time, etc.) (sub: perf) Task neither bug nor feature but something that needs to be done in support of either
Projects
None yet
Development

No branches or pull requests

4 participants