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

autocomplete-lua slowing down/crashing atom #24

Open
Nexela opened this issue Sep 19, 2017 · 6 comments
Open

autocomplete-lua slowing down/crashing atom #24

Nexela opened this issue Sep 19, 2017 · 6 comments

Comments

@Nexela
Copy link

Nexela commented Sep 19, 2017

I have narrowed down an extreme perfomance / memory leak to autocomplete-lua. This just showed up recently in atom.

With the autocomplete-lua package enabled and my project opened Atom starts slowing down and I can watch atoms memory usage climb past 2gigs until it finally becomes unresponsive and crashes.

The same happens with previous 3 versions of autocomplete-lua so possibly a change in Atom that caused this?

@dapetcu21
Copy link
Owner

Thanks for the report. I'll take a look. Can you provide a bit more context? What are you using autocomplete-lua for?

@Nexela
Copy link
Author

Nexela commented Sep 19, 2017

I use it mostly for the completions from require'd modules.
Using the latest Atom (or Atom Beta) and a fresh .atom folder with just this extension the slowdown showed up.

Using this repository https://github.com/Nexela/PickerExtended/tree/3.0.0
editing control.lua the problem shows up just start typing away and you will notice it getting slower and slower and memory usage climbing.

@dapetcu21
Copy link
Owner

Thanks for the details. I'll try to reproduce. I should be able to look into this and other maintenance issue for this package this weekend

@dapetcu21
Copy link
Owner

By the way, in your project you can just replace the full absolute path in your .luacompleterc with just { "cwd": "." }

@dapetcu21
Copy link
Owner

dapetcu21 commented Sep 24, 2017

I can definitely reproduce the leak (almost to the point the heap profiler crashing) and I've been trying to debug it for the past two hours with no success. The codebase as it is now is pretty messy (mostly due to storing types in custom, mutable data structures which are hard to debug). I've been mulling these past weeks on the idea of a full rewrite using proper control flow analysis theory. That might take a while, though. Meanwhile, I'll add a config option to just autocomplete the current file (ignoring require()-d modules) in the next release. That should, at least, mitigate the issue.

@AGulev
Copy link

AGulev commented Jun 4, 2018

Yea, i have the same issues when the project gets bigger

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants