-
Notifications
You must be signed in to change notification settings - Fork 79
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
Memory leak? #129
Comments
Thanks for reporting. I think we would need more details. Would you be keen troubleshoot and see if you can perform specific actions and measure memory usage before and after? Can't say I have any Emacs experience in this space. I could use the help. |
What specific actions or extra details do you suggest? Happy to help. |
Can't say I'm familiar with debugging Emacs memory issues. Anything you can do to try to isolate user actions that lead to memory consumption (and measure) would be helpful. If you figure out a way to measure (maybe after explicitly invoking garbage collector), could also be used to check if memory is restored when shell buffers are killed. |
Source highlighting is pretty innefficient at the moment. Added Also, it'd be good to know if the sluggishness goes away if the shell buffers are killed. |
I will try it out. I'm optimistic, because the times at which I feel the greatest lag are indeed when the shell refreshes to highlight a new code block (at times Emacs goes blank until the buffer refreshes). Buffers killed doesn't seem to help though. |
I can confirm that it is the block highlighting that is affecting performance. Might be worth optimizing. |
Not had a chance to look into this. In the mean time, maybe this helps (after clearning or killing shell buffers)? https://indieweb.social/@lispi314@mastodon.top/111184372065140896 (when (symbol-function 'malloc-trim)
(add-hook 'post-gc-hook #'malloc-trim)) |
Thanks for the suggestion. 'malloc-trim is not defined though in my version of emacs (Mac osx) |
Looks like I've run into some issues as well. I've been having some sluggish/slow behavior in emacs for a while but couldn't pin it down until now. Looks like chatgpt-shell syntax highlighting is the source. Only when there is visible colorized text (eg code block), that's when the slowness kicks in. Turning off syntax highlighting for now |
Ah have not turned on syntax coloring since then. I did quick testing and it seems to be fine now (But again it was a very limited test). I've changed my config back to having syntax coloring so I'll know more if this still an issue in the coming weeks. Personally I'm okay with closing. Can always re-open if it didn't fix it |
Thanks! Gonna close the issue for now. If you see it again, please reopen. |
Whenever I use
chatgpt-shell
I notice the performance of my Emacs slowly degrading and it's memory footprint increasing to amazing sizes.The text was updated successfully, but these errors were encountered: