-
Notifications
You must be signed in to change notification settings - Fork 132
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
high CPU and memory usage on Linux #654
Comments
Thanks for the detailed error report. Can you provide the flamegraph in another format that I can explore? And let me know how you created it, I’m curious if this was generated by Helix. |
I overlooked this comment! That was also my hunch, so thanks for clarifying this. We should definitely throttle the shell check calls. |
I generated the flamegraph following the instructions in this repo. (it would be interesting to have helix have a perf integration). I pulled up my zsh history and got the commands I used. You use perf to launch the process and take samples at 100Hz and run for 10 seconds. You then parse the perf output and then use the perl scripts from the flamegraph repo to take that data and create the svg file. There are other transformations one can do but I'm not the most adept at flamegraphs, and I included it since you asked for one in the MacOS issue I linked.
edited to add:
Huh, today I learned one can upload a gzipped tar ball to a github issue comment. I have the raw perf output and the transformed files as well as the final flamegraph. |
Thanks for the details! A new version But I would like you to verify if the issue is resolved. Thanks. :) |
@LadySerena thanks. It is very odd that ShellCheck consumes so much CPU on Linux... If you have time then I would appreciate if you tested out version 4.2.4 also that includes a simpler debouncing. |
Note that we have also fixed a bug causing memory leaks and high CPU usage for workspaces with many files – this has been released as [email protected] and the vscode extension 1.26.0. |
Hey actually that last PR fixed the resource usage problem. Thank you for getting the patches together :D |
Description
I also encountered the same error as this issue on macos. I got about 10 seconds of perf events before I needed to exit the program, since it causes my system to become unresponsive. Let me know if you need more info. I'm still a newb with perf, so I wasn't able to sift out the signal from the noise.
Environment
uname output
helix version
bash-language-server version
node version running under
nvm
Related Issues
Looking at Helix's issue tracker there might be similar to this one but I'm not 100% sure.
Full Flamegraph
flamgraph
Steps to reproduce
Open my
zshrc
file(On arch the packagers made the binary name
helix
instead of the defaulthx
)hx $PATH_TO_FILE
helix $PATH_TO_FILE
edit the
helix-dev2
function and add a tmux command. This bug is that a bunch (20+) shellcheck processes spin up and exhaust the system of resources.full zsh file
The text was updated successfully, but these errors were encountered: