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

Add performance validations to language server extended services #33151

Closed
IMS94 opened this issue Oct 11, 2021 · 1 comment
Closed

Add performance validations to language server extended services #33151

IMS94 opened this issue Oct 11, 2021 · 1 comment
Labels
Area/Performance Performance related issues. IceBox Older issues that are not being actively worked on but may be revisited in the future. Team/LanguageServer Language Server Implementation related issues. #Compiler Type/Task

Comments

@IMS94
Copy link
Contributor

IMS94 commented Oct 11, 2021

Description:
With more and more extended language server services getting introduced to the language server, number of requests served by LS at a given time increases. As of now, when a user makes a change to a document, apart from usual completion/codeaction requests, several other requests come from the vscode side. Examples are the diagram overview, executor positions and package components requests can be considered.

Since some of these requests rely on compilation, vscode may become unresponsive (latency in diagnostic publishing, etc) when the source code becomes larger. In LS, we have introduced the cancellation support to address this. Since no similar mechanism is available for extended services yet, irrelevant requests may take up CPU while the source code has moved on from that state.

To identify this kind of behavior, a mechanism is required to identify performance deviations.

Describe your task(s)
Suggestion is to implement a special type of performance tests with the following steps.

  1. Simulate opening a text document and sending a completion request at the given cursor position. Measure time taken for response.
  2. Simulate the above steps while sending extended service requests at the same time. Measure time taken.

Perform the above steps several times to eliminate outliers and get the average response times. Then, compare for the time difference in those two operations. Check if the extended service has affected the core LS features (completions in this case). We can see if the response time has increased than a given percentage.

In summary, we take the LS only scenario as the baseline and compare the same while being interfered by extended services. We should propose a test framework (an abstract class may be) which can be extended by extended services and add their own tests.

@IMS94 IMS94 added Type/Task Team/LanguageServer Language Server Implementation related issues. #Compiler Area/Performance Performance related issues. labels Oct 11, 2021
@anupama-pathirage anupama-pathirage added the IceBox Older issues that are not being actively worked on but may be revisited in the future. label Nov 21, 2024
@anupama-pathirage
Copy link
Contributor

We are closing this issue due to inactivity. If you need further assistance or have additional input, feel free to reopen it. Thank you for helping us maintain a relevant and focused issue list!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area/Performance Performance related issues. IceBox Older issues that are not being actively worked on but may be revisited in the future. Team/LanguageServer Language Server Implementation related issues. #Compiler Type/Task
Projects
None yet
Development

No branches or pull requests

2 participants