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

ConfigurationModel is slow #37426

Closed
jrieken opened this issue Nov 1, 2017 · 3 comments
Closed

ConfigurationModel is slow #37426

jrieken opened this issue Nov 1, 2017 · 3 comments
Assignees
Labels
perf perf-startup verification-needed Verification of issue is requested verified Verification succeeded
Milestone

Comments

@jrieken
Copy link
Member

jrieken commented Nov 1, 2017

Related to #34353 and #34282. When you profile start and look at the time spend in the configuration service you'll notice that it's still very slow.

Paste require('vs/base/node/startupTimers').ticks().forEach(tick => console.log(tick.name, tick.duration)) in the dev-tools-console and see that ~100ms is spend in building/merging/deduping the configuration model.

Apart from clone it also seems that a lot of time is spend in arrays#distinct which as a potential runtime of O(n2)

screen shot 2017-11-01 at 18 15 06

@vscodebot vscodebot bot added the debug Debug viewlet, configurations, breakpoints, adapter issues label Nov 1, 2017
@jrieken jrieken added perf and removed debug Debug viewlet, configurations, breakpoints, adapter issues labels Nov 1, 2017
@jrieken jrieken assigned sandy081 and unassigned weinand Nov 1, 2017
@sandy081
Copy link
Member

sandy081 commented Nov 2, 2017

@jrieken Thanks for the report.

May I know if it is slower than before ?

@jrieken
Copy link
Member Author

jrieken commented Nov 2, 2017

May I know if it is slower than before ?

No clue, you can measure it with an old version of VS Code

@sandy081
Copy link
Member

sandy081 commented Nov 9, 2017

This is the new picture after doing following improvements:

  • Merge, clone and freeze only when the configuration is requested.
  • Fix from @jrieken - ConfigAwareContext is slow  #37539
  • Register and trigger configuration and default configurations all at a time.
  • Merge user configuration service and workspace configuration service to remove duplicate merges and triggering.

image

@sandy081 sandy081 closed this as completed Nov 9, 2017
@sandy081 sandy081 added this to the November 2017 milestone Nov 9, 2017
@sandy081 sandy081 added the verification-needed Verification of issue is requested label Nov 9, 2017
@jrieken jrieken added the verified Verification succeeded label Dec 7, 2017
@vscodebot vscodebot bot locked and limited conversation to collaborators Dec 24, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
perf perf-startup verification-needed Verification of issue is requested verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

3 participants