This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 160132 - Editor chokes on large java source files
Summary: Editor chokes on large java source files
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Navigation (show other bugs)
Version: 6.x
Hardware: All Windows Vista
: P3 blocker (vote)
Assignee: Tomas Zezula
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2009-03-11 20:46 UTC by scott_pavetti
Modified: 2015-03-10 10:21 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
File that causes unresponsive IDE (706.66 KB, text/plain)
2009-03-11 20:50 UTC, scott_pavetti
Details
messages.log (52.40 KB, text/plain)
2009-03-13 19:08 UTC, scott_pavetti
Details
Profiler screenshot (121.74 KB, image/png)
2015-03-10 10:21 UTC, Tomas Zezula
Details

Note You need to log in before you can comment on or make changes to this bug.
Description scott_pavetti 2009-03-11 20:46:54 UTC
It takes the editor upwards of 30+ seconds to color (and whatever else happens in the background at this time) a source 
file.  (4GB Ram, Dual Core 2.0GHz Xeon Processor)  In the mean time, the IDE is unresponsive except for 
maximize/minimize window buttons.  Another file (725K source file causes the IDE to be unresponsive for an undetermined 
amount of time, and CPU utilization to go to 100%.  I quit waiting at 15 minutes.  During the unresponsive time 
NetBeans will not close, it  has to be terminated manually with a task manager.  I can edit this large file from 
another editor and have it be useful, as compilation does not seem to be affected.
Comment 1 scott_pavetti 2009-03-11 20:50:04 UTC
Created attachment 78075 [details]
File that causes unresponsive IDE
Comment 2 Vitezslav Stejskal 2009-03-13 12:18:29 UTC
Thanks for the file. I tried it in current dev build and it really makes the IDE froze, there is no deadlock though. I
managed to open the file successfully, but I had to close the Navigator window. Even after that there still were some
java tasks running on background (computing hints, maybe others), but the IDE was reasonably responsive. Could you
please capture several threaddumps when the IDE is frozen and attach them here. Also please attach your
<ide-userdir>/var/log/messages.log file.
Comment 3 scott_pavetti 2009-03-13 19:08:16 UTC
Created attachment 78163 [details]
messages.log
Comment 4 scott_pavetti 2009-03-13 19:10:02 UTC
I have submitted the messages.log.  Thank you for looking at this, I appreciate it!
Comment 5 Tomas Zezula 2015-03-10 10:20:16 UTC
The performance was improved for the attached file.
See attached screenshot.
The parsing + attribution of the file 1.752s (SourceCache.getResult)
Editor tasks (which are cancellable and do not block the IDE, when more priority requests come they are cancelled) 6.4s, most time taken by Hints: 4.9s

We may set some limit and disable some editor features when file is bigger then some limit. But it will not be very helpful as the long taking tasks are cancellable and disabling non cancellable parsing will disable all navigation.
Comment 6 Tomas Zezula 2015-03-10 10:21:02 UTC
Created attachment 152522 [details]
Profiler screenshot