-
Notifications
You must be signed in to change notification settings - Fork 7
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
Adding Startup Time Analysis Capability #50
Comments
Hi @mackoj , first of all, I'm sorry for the late reply, the last weeks were quite busy for me. Thanks for the suggestion, it's an interesting idea and MetrickKit really gives tons of metrics we could explore. General thoughtsPre-main
Post-main
Complexities
Questions
|
Some other thoughts
Curious to hear your thoughts :), even thought there are things to consider, we may still be able to find a valuable path |
Hi @marinofelipe sorry for the delayed response.
At the moment, it's quite basic. I've added a basic MetricKit implementation in the MeasurementApp that writes the data to a specific path. I haven't initialized it; I just want to see how it performs from a linking point of view. I would love to have startup impact information, similar to what's discussed in this article: https://www.emergetools.com/blog/posts/comparing-top-analytics-sdks-for-ios.
If MetricKit can support it I will have this data too. I will need to look more in depth what is available.
So far, I believe it could still be valuable to quickly gauge the potential impact, especially on pre-main and for comparing dynamic linking versus static or mergeable libraries(https://www.emergetools.com/blog/posts/make-your-ios-app-smaller-with-dynamic-frameworks / https://www.humancode.us/2024/01/02/all-about-mergeable-libraries.html). For me, the goal is to compare SDKs before implementation, and being able to track the evolution of the SDKs I ship based on these metrics can be really helpful.
True
I don't think all MetricKit data is relevant or even accessible for a tool like swift-package-info. However, some of them can be really helpful and maybe leveraged in a more static fashion. I do agree that it doesn't align with this project's direction, but I don't think we can't leverage it to our advantage. |
Hi @mackoj , I'm sorry for taking so long to answer but I didn't manage to focus on Open Source the past couple weeks.
Nice, let me know how far you've got. It definitely make sense from a linking point of view.
From what I recall, MetricKit has the total launch time duration, see here, which is a a very good starting point. For a detailed pre and post-main I found the App Launch Instruments a great option, but for our use case it would further complicate things and significantly extend the swift-package-info runtime.
Agreed. Let's see what we can have, a simple static analyzes of linking is already a great feature 😄 Again, in case you made progress, let me know how it went. I've done one thing or two around launch times and measuring app performance at work, especially when we further scaled and modularized our app, so I'd be happy to collaborate with you on this one. |
Hello @marinofelipe,
I'm reaching out to propose an enhancement that I believe could open the door to a plethora of new valuable metrics.
I aim to enable users to extract the startup time in order to compare with or without the SDK. The proposed functionality would involve executing the application both with and without the SDK multiple times, capturing the startup times for each iteration. Subsequently, the average startup time for each scenario would be calculated, allowing users to compare the performance impact of integrating the SDK.
The output could be presented as either the percentage increase in startup time or the absolute time difference. I am open to discussing the most appropriate format based on the project's requirements and user preferences.
Additionally, implementing this feature would pave the way for extracting more data from MetricKit in the future.
But implementing this will require
MeasurementApp
to run on device.Ressources
I would appreciate your thoughts and feedback.
The proof of concept have generated this.
Thank you
The text was updated successfully, but these errors were encountered: