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 119393 - Toggling between tabs (java code) is slow for large projects.
Summary: Toggling between tabs (java code) is slow for large projects.
Status: RESOLVED DUPLICATE of bug 119415
Alias: None
Product: editor
Classification: Unclassified
Component: Navigation (show other bugs)
Version: 6.x
Hardware: PC All
: P3 blocker (vote)
Assignee: issues@editor
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2007-10-18 18:41 UTC by darrinps
Modified: 2007-11-05 13:40 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Thread dump (115.95 KB, text/plain)
2007-10-19 16:19 UTC, darrinps
Details

Note You need to log in before you can comment on or make changes to this bug.
Description darrinps 2007-10-18 18:41:10 UTC
I have a fairly large project (about 400 java classes in the project and another one to two thousand supporting classes
in jar files) and when I try to go from java class to java class in the editor by clicking on one tab and then another,
a three second delay can be seen.  Doing this exact same thing on the exact same files in the exact same project on the
exact same machine right afterward but using Eclipse, the delay is less than a second.
Comment 1 darrinps 2007-10-18 18:45:03 UTC
Note that this isn't just a problem with toggling between java classes in the editor.  This same delay shows up when you
toggle from another application to Netbeans.

For example you could have Netbean's help up on top of part of Netbeans, and say, Textpad up in front of them both.  If
you minimize Textpad, the Netbean's help  shows up immediately, but the Netbeans IDE takes several seconds to finally
refresh.

Here is some info that may be of help:

Product Version: NetBeans IDE Dev (Build 200710170000)
Java: 1.6.0_03; Java HotSpot(TM) Client VM 1.6.0_03-b05
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
Comment 2 Jan Lahoda 2007-10-18 18:50:01 UTC
Could you please do a few (5-10) thread dumps while the IDE is frozen? This might be very helpful. Thanks.

http://wiki.netbeans.info/wiki/view/GenerateThreadDump
Comment 3 darrinps 2007-10-18 22:21:13 UTC
Note that going from a tab with a java class to a tab with a .txt file is MUCH slower than going from java to java. 
I've noticed other problems with respect to performance for .txt files as well, so there is something going on here. 
The size of the .txt file doesn't seem to make too much difference as even a 150 line file causes these types of issues.
Comment 4 Vitezslav Stejskal 2007-10-19 09:38:33 UTC
What is the memory footprint of the IDE? And what is your HW, especially the amount of memory? Does clicking the memory
bar (ie. forcing full garbage collection) make any difference? Could you please make a few thread dumps as suggested by
jlahoda? Thanks. Also, there are some performance tips on the wiki:
http://wiki.netbeans.org/wiki/view/NetBeansUserFAQ#section-NetBeansUserFAQ-Performance
Comment 5 darrinps 2007-10-19 16:19:23 UTC
Created attachment 51303 [details]
Thread dump
Comment 6 darrinps 2007-10-19 16:20:04 UTC
Memory footprint is 170 with a high of 319.  I tried forcing garbage collection but it didn't make any difference with
respect to speed.

Attaching thread dumps as requested
Comment 7 Petr Nejedly 2007-10-19 17:39:27 UTC
So both this and issue 119415 have the same root problem and that is slow filesystem access during the tab switch,
closing as dup.
BTW: is the slow text file inside a project or standalone?


*** This issue has been marked as a duplicate of 119415 ***
Comment 8 Jan Lahoda 2007-10-19 18:22:32 UTC
For the record, there already is a bug about slow switching between Java files: issue #101027.
Comment 9 darrinps 2007-10-19 18:25:45 UTC
The test file is inside the project.