-
Notifications
You must be signed in to change notification settings - Fork 1.7k
editor is really slow #3945
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
This looks like slowness caused by a low memory situation and (my guess) swapping. We should up the default max memory to 2GB for the Editor. 1GB is not enough for serious development. |
I'm running with 4GB now. The interruptions are less often now, but when they hit I still have 2 secs lag before a new character appears. |
Just to confirm we are on the same page... you are saying that you have modified the default DartEditor.ini file (see below) to have -Xmx4096m ? and perhaps also something like -XX:MaxPermSize=512m ? -consoleLog Set owner to @floitschG. |
Didn't change the MaxPermSize, but yes for the Xmx4096. |
This is easily reproducible by simply loading the lib/compiler and just editing a few files. Could this be a memory leak, it seems this is getting worse and worse after a few hours of (actually pretty light) usage. Saving is also taking considerably longer now than before. I saw 20+ second pauses by simply adding a simple void function with an empty body and saving (just writing the function is also slow due to the lag when actually writing, it seems that if you pause for just a second there is a considerable lag when you start typing again) |
Thanks for the suggestions. I ran build 9258 and opened the lib/compiler ... all was fine. I'm testing this on Mac it appears you are using Linux and OpenJDK... I'll test on that next. In the meantime... cc @ricowind. |
I haven't tried "Re-analyze Sources" yet. It seems that the editor is behaving better now. I attributed that to the fact that I'm now running with MaxPermSize=512m and Xmx4096m, but, for testing, I switched back to the defaults yesterday evening, and I was able to edit Dart code again. |
With the default settings I get again horrible performance (waiting 2 minutes to recover after a save). I'm not sure what exactly eats up the memory, though. Attachments: |
Switching priority to High. This makes the editor unresponsive and hurts usability. Even with 4 gigs I eventually run out of memory: $ PATH=/usr/local/buildtools/java/jdk-64/bin:$PATH jmap -heap 2695 using thread-local object allocation. Heap Configuration: Heap Usage: Removed Priority-Medium label. |
How many opened files do you usually have when memory problem happens? |
3 open views. |
Forgot to say: I didn't notice any correlation between the number of opened files and slowness. When it gets slow again I will see if closing some files will free the memory. |
Just had this problem with 3 opened files. The editor is getting unresponsive. Attaching to process ID 15306, please wait... using thread-local object allocation. Heap Configuration: Heap Usage: |
Do you still have this issue with the latest build? There have been some very significant performance and memory usage improvements made over the last few days. |
Current build seems to be much better. I used this editor yesterday during the afternoon, and continued using it today. Things start to get slow again. I'm pretty sure that a restart of the editor will help, though. Note: I frequently replaced the files in the background (git checkouts). This yields tons of errors, which I quell by "don't analyze"/"analyze" (issue #3863). Could be that this is partly responsible for the memory leak. build 9695: using thread-local object allocation. Heap Configuration: Heap Usage: |
Could you please next time generate heap dump, compress it and send to the Editor team or upload somewhere? So, we could see where is problem exactly. http://docs.oracle.com/javase/6/docs/technotes/tools/share/jmap.html |
I think this is now fixed. Please reopen if you see this problem again. Added Fixed label. |
I have already submitted a feedback on the slowness of the editor. But since that's probably difficult for you to track down I also run jstack every second for some time.
I have attached the output of the stack dumps. (Not sure it will help, but maybe there is something in there that points you to the problem).
Attachment:
jstack (4.52 MB)
The text was updated successfully, but these errors were encountered: