-
Notifications
You must be signed in to change notification settings - Fork 378
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 usage continuously increasing #185
Comments
This may overlap with ternjs/tern_for_vim#22 -- which is caused by the fact that the Tern server does not have a strategy for dealing with giant codebases, and will happily keep loading code and building graphs until the machine falls over. It's strange that this only happens after a while for you, though. Is Tern giving useful responses in the meantime? |
We're experiencing the same issue in Brackets sprint 27. I just verified that this issue is introduced by 2010f93. |
That seems unlikely -- the patch you point to is a simple change in initialization order of the modules, it shouldn't have any impact on run-time performance or memory use. |
I did verify it by restoring the initialization order in infer.js and replacing the def.js to the version before this commit and memory consumption is back to normal. |
That's interesting. But I'm not going to revert a commit without understanding how it can cause such a regression. Do you have a script or scenario that allows me to easily reproduce the memory blowup? |
I used ExtJS to reproduce the issue. And I also narrow it down to only two js files -- Ext.js and Ext-debug.js. |
Yes, but since you are talking about memory use increasing over time, I guess there are some kind of calls to tern going on during this time. Or is this a situation where it hangs and fills up memory? |
Actually, you don't have to do anything in Brackets. Just keep these two files in the project folder, open any js file (can be an empty file) and watch the memory consumption in Processes tab of Windows Task Manager. |
I think this is a separate issue from the one reported initially here given that the Ext example runs out of control right away and the original reporter here had memory usage increasing over a period of minutes. I will open a separate issue. |
I'm using TernJS on Sublime Text 2. My project has THREE.js in it, and 2-3 other small Javascript scripts in it. Without TernJS running, my memory usage is at 50,000K. Once I run TernJS, it goes up to 500 right away, which isn't too bad, but as time passes, every 5 minutes or so, Sublime completely freezes and the memory usage goes up ~250,000k, up until it gets to 1,500,000K where Sublime straight up crashes.
I tried asking on the TernJS-ST2 repo, but this looks more like an issue with TernJS itself. Couldn't find anything like it in the issues looking through (does GitHub not have search on the issues?). THREE.js is a fairly big library, but it doesn't explain the memory usage going up like that.
The text was updated successfully, but these errors were encountered: