-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Infinite RAM usage #19551
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
Comments
Another issue is helpful, thanks. In terms of what could be immediately be done, disabling cache priming ("indexing") could help, but that largely defers the memory usage growth: if you're to open/visit the files in question, you'll largely end up with similar memory usage. This does mean the initial LSP requests will take longer, but if you have a large Cargo workspace but only edit a small subset of crates, this could help a bit. As for if we're treating this as a bug: we are. We've had reports of rust-analyzer's memory usage increasing dramatically on some projects since #18964 landed, but haven't determined why some projects experience the memory usage spike. Is the code in question open-source...? |
Having read most of the threads about this issue, I've already disabled cachePriming on this project. I cannot share code source but if you have specific questions about what could be special about our project, please ask. |
Can you run |
I didn't find the path of the rust-analyzer binary used by the extension so I used rust-analyzer version
|
We've recently added some new functionality to rust-analyzer that provides more detail about what is being analyzed. If you're to clone and build rust-analyzer from source using |
Here is the report with commit
|
Just for reference: #19402 |
I don't know if I should be opening an other issue for this since there is already several issues about RAM usage but I can't find a definitive answer.
Is this RAM usage an expected behavior of rust-analyzer or symptoms of a bug ?
The RAM usage seems to be growing through the day.
Here is some information about the project size (it's a cargo workspace of ~100 crates).
Installed version is
0.3.2370
.The text was updated successfully, but these errors were encountered: