Project Name | Stars | Downloads | Repos Using This | Packages Using This | Most Recent Commit | Total Releases | Latest Release | Open Issues | License | Language |
---|---|---|---|---|---|---|---|---|---|---|
Vim Startuptime | 162 | 10 months ago | 8 | December 06, 2022 | mit | Go | ||||
A small Go program for better `vim --startuptime` alternative | ||||||||||
Startuptime.vim | 132 | 6 years ago | 8 | mit | Vim script | |||||
Breakdown Vim's --startuptime output | ||||||||||
React Native Startup Time | 102 | 1 | 2 | a month ago | 8 | August 14, 2022 | 4 | mit | Java | |
measure startup time of your react-native app | ||||||||||
Lambda Test | 79 | 8 years ago | 1 | mit | Shell | |||||
Test (pseudo) AWS runtime startup time | ||||||||||
Startup Time | 19 | 4 years ago | epl-2.0 | Clojure | ||||||
Clojure startup time example | ||||||||||
Node Coffee Cache | 19 | 9 years ago | 2 | mit | JavaScript | |||||
Caches the contents of required CoffeeScript files so that they are not recompiled to help improve startup time | ||||||||||
Vim Plugins Profiler | 15 | a month ago | 6 | August 15, 2021 | Python | |||||
Utility to output a sorted list of VIM plugin startup times in millisec. | ||||||||||
Zsh Startup Timer | 14 | 7 years ago | 1 | mit | Python | |||||
A zsh plugin to print the time it takes for the shell to start up | ||||||||||
Startup Time | 13 | 3 years ago | 5 | September 11, 2019 | artistic-2.0 | Ruby | ||||
A command-line benchmarking tool to measure the startup times of programs in various languages | ||||||||||
Daggervsroboguice | 10 | 10 years ago | Java | |||||||
Demo projects used to test startup time between a dagger-based project and a RoboGuice-based project |
This project was created to compare start and injection times required to support dependency injection with both the RoboGuice and dagger DI libraries.
One base project defines 30 interfaces and 29 implementations, each injecting the next. This leads to a linear chain of dependencies, 30 classes deep. At this time there are no circular dependencies or other complexities in the dependency tree. The 30th implementation is left for consumers to define, though the dependent implementation requests injection from the base project.
The other two projects are implemented with the same functionality using different DI libraries. RoboTest uses RoboGuice 2.0 and Dagger uses the latest dagger implementation.
Java JDK 1.6+ maven 3+ Android SDK 16+ git
git clone git://github.com/square/dagger.git
cd dagger
mvn install
from BaseProject, run
mvn install
from RoboTest, run
mvn install
Deploy to a connected device with mvn android:deploy
from DaggerTest, run
mvn install
Deploy to a connected device with mvn android:deploy
RoboGuice, as expected, has a larger start up cost due to its run-time module executing and binding validation. Dagger does its validation at compile time, removing nearly all of that cost at start up.
Running the built APKs from this source gets the following results:
Additional profiling found that setContentView takes ~35ms for both applications with onCreate using up the remaining time. So operating under the assumption that onCreate is only spending time instantiating and providing / injecting objects:
Keep in mind that RoboGuice is preparing itself to provide much more than the 30 classes we've defined for this test (services, contexts, etc.), so this isn't quite an apples to apples test; more of an apple pie to apples comparison. Perhaps a Guice vs. Dagger comparison would be more apt, but until we have a RoboDagger (sounds painful), this will have to suffice. That said, I've done profiling of RoboGuice and its initialization cold start is a direct result of its use of Guice. That 400ms startup cost can be traced to Guice's module execution and binding validation, not the RoboGuice code that wraps it.