Skip to content

testing: improve performance of large test discovery - #22414

Closed
Connor Peet (connor4312) wants to merge 2 commits into
mainfrom
connor4312/improve-test-discovery-perf
Closed

Connor Peet (connor4312) wants to merge 2 commits into
mainfrom
connor4312/improve-test-discovery-perf

Conversation

@connor4312

Copy link
Copy Markdown
Member

Avoids expensive string conversions and (to a lesser degree) buffer concatenations. Reduces time in the extension host in the lsprotocol repo from 17s -> 950ms for me.

Original profile:
vscode-profile-2023-11-02-16-35-20.cpuprofile

Profile with these changes:
vscode-profile-2023-11-02-17-27-45.cpuprofile

Avoids expensive string conversions and (to a lesser degree) buffer
concatenations. Reduces time in the extension host in the lsprotocol
repo from 17s -> 950ms for me.

Original profile:

Profile with these changes:
@connor4312
Connor Peet (connor4312) force-pushed the connor4312/improve-test-discovery-perf branch from ed60acf to 5a24096 Compare November 3, 2023 01:43
@connor4312 Connor Peet (connor4312) added the debt Code quality issues label Nov 3, 2023
@karthiknadig

Copy link
Copy Markdown
Member

Connor Peet (@connor4312) we are working on replacing this with vscode-jsonrpc as it provides the API to do IPC, and get rid of this custom JSON-RPC implementation we have. One thing to check is that same issue does not exist in vscode-jsonrpc.

@connor4312

Copy link
Copy Markdown
Member Author

It looks good at first glance, and it avoids both the pitfalls I fixed in this PR. I'll validate when it lands 🙂

@karthiknadig

Copy link
Copy Markdown
Member

We are working on moving the communication to use vscode-jsonrpc. Closing this in favor of that change #22177

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

debt Code quality issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants