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

filters.ts' matchesSubString() performs badly in some cases #35346

Closed
chrmarti opened this issue Sep 29, 2017 · 1 comment
Closed

filters.ts' matchesSubString() performs badly in some cases #35346

chrmarti opened this issue Sep 29, 2017 · 1 comment
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues search Search widget and operation issues verified Verification succeeded
Milestone

Comments

@chrmarti
Copy link
Contributor

E.g., matchesSubString('aaaaaaaaaaaax', 'aaaaaaaaaaaaaaaaaaaaaaaaa') calls _matchesSubString() 38 million times due to the backtracking being done.

This is used for the fuzzy highlighting in QuickOpen. It seems to have been there for some time, not a recent regression.

/fyi @bpasero

@chrmarti chrmarti added the search Search widget and operation issues label Sep 29, 2017
@chrmarti chrmarti self-assigned this Sep 29, 2017
@chrmarti chrmarti added this to the October 2017 milestone Sep 29, 2017
@bpasero
Copy link
Member

bpasero commented Sep 29, 2017

@chrmarti thanks for spotting this, this method is literally 5 years old I would say and probably has been used since then in many cases.

@bpasero bpasero added the freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues label Sep 29, 2017
@chrmarti chrmarti added the bug Issue identified by VS Code Team member as probable bug label Oct 3, 2017
@mjbvz mjbvz added the verified Verification succeeded label Nov 1, 2017
@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 17, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug freeze-slow-crash-leak VS Code crashing, performance, freeze and memory leak issues search Search widget and operation issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

3 participants