You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 3, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Mar 3, 2023. It is now read-only.
Reduce the number of modules loaded by the main process on startup #19269
FY2019Q5 atom perfMore information: https://github.com/github/pe-atom-log/issues/728stale
We want to reduce the number of JS modules that get loaded during the startup time by the Atom main process in order to improve the startup time.
In some situations, we can just deduplicate dependencies (or remove unneeded dependencies) to get a net reduction of loaded modules, in some other situations we may need to delay the loading of modules (which would just delay the cost to whenever that module is used).
Hypothesis
By delaying the loading (and parsing/evaluation) of non-essential JS modules, we can speed up the startup of Atom
Context
Atom timing data
Currently, the Shell load time (which is one part of the startup time that corresponds to the time it takes from the first JS file gets executed in the main process until the Atom window gets opened) is the main contributor to the Atom startup time.
For the last 5 Atom versions, the shell load time on real users have been around ~1.1s (median time), while the window open time has been around ~160ms.
Current list of required modules
Currently, Atom's main process loads 396 JS modules before starting a new window (~200 of them are unique).
There's some duplication of modules (fs-extra) and some modules that shouldn't be needed since they are provided by nodejs core library (nodegit-promise, promisify-node).
How to debug the required modules on startup
I've used some hacky code to locally plug into the require system of the main process and store each single loaded module.
This issue has been automatically marked as stale because it has not had recent activity. Because the Atom team treats their issues as their backlog, stale issues are closed. If you would like this issue to remain open:
Verify that you can still reproduce the issue in the latest version of Atom
Comment that the issue is still reproducible and include:
What version of Atom you reproduced the issue on
What OS and version you reproduced the issue on
What steps you followed to reproduce the issue
Issues that are labeled as triaged will not be automatically marked as stale.
FY2019Q5 atom perfMore information: https://github.com/github/pe-atom-log/issues/728stale
Activity
stale commentedon May 6, 2020
Thanks for your contribution!
This issue has been automatically marked as stale because it has not had recent activity. Because the Atom team treats their issues as their backlog, stale issues are closed. If you would like this issue to remain open:
Issues that are labeled as triaged will not be automatically marked as stale.