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 27774 - Speed up navigation in main menu
Summary: Speed up navigation in main menu
Status: RESOLVED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Window System (show other bugs)
Version: 3.x
Hardware: All All
: P1 blocker (vote)
Assignee: Petr Nejedly
URL: http://performance.netbeans.org/respo...
Keywords: PERFORMANCE
Depends on: 28739 28912
Blocks: 26581
  Show dependency tree
 
Reported: 2002-10-03 14:59 UTC by _ rkubacki
Modified: 2008-12-23 13:41 UTC (History)
3 users (show)

See Also:
Issue Type: TASK
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ rkubacki 2002-10-03 14:59:39 UTC
Pull-down submenus do not keep up with the mouse.
Comment 1 _ pkuzel 2002-10-25 18:25:39 UTC
I think that Swing adds extra 200ms to eliminate temporary paints. It
you open the menu explicitly by keystroke or mouse click you get times
shorter by 200ms.

May be that we should instruct Swing to defer these paints by shorter
time (100ms).
Comment 2 David Simonek 2002-11-19 16:48:47 UTC
Dafe's measurements - testing conditions: PC Dell Pentium III, 600Mhz,
512 MB memory, JDK 1.4.1, Netbeans Main trunk build, mounted sampledir
local filesystem, opened 8 java source files, 3 plain text files.
times in milliseconds, first number shows first invocation, followed
by subsequent invocations.
File 266, 47
Edit 265, 31
View 937, 110
Project 235, 32
Build 359, 47
Debug 250, 47
Versioning 515, 31
Tools 641, 31
Window 313, 47
Help 406, 16
Comment 3 Tomas Pavek 2002-11-20 16:42:12 UTC
My observation is similar. Most problematic are View and Tools menu.
Speeding up these two at least would be nice.
Comment 4 Petr Nejedly 2002-11-21 14:28:12 UTC
The view menu popup time is caused by "Javadoc Indices" menu item
which is provided by JavaDoc module's IndexOverviewAction.
See issue 28912

Tools menu seems OK on subsequent invocations.

I have some modifications to the menu infrastructure that takes the
subsequent menu invocations to the times *very* close to the plain
precomputed JMenu invocations, stay tuned.
Comment 5 Marian Mirilovic 2002-11-21 16:54:03 UTC
Marian's measurement (time in milliseconds):
conditions: 
 - SUN UltraSparc60 / 512 MB RAM / Solaris 5.8 / CDE
 - JDK1.4.1(01)
 - [nb_dev](200211140100) , MDI
        - mounted sampledir

bring main menu by mouse:
 Window                  271     47      44
 File                    170     31      25
 Edit                    198     53      37
 View                    567     115     108
 Project                 120     32      53
 Help                    216     19      22
 Debug                   114     44      30
 Versioning              307     68      24
 Tools - selected
  - Filessytems node    603     72      49
  - Local FS            1111    64      51
  - package             717     41      29
  - java file           787     48      52
 Build - selected
  - folder (examples)   422     44      33
  - java (ColorPreview) 343     71      30              
 

Test cases are described on page :
http://performance.netbeans.org/qa/TestSuites.html#expanding_every_main_menu_except_tools
Comment 6 _ rkubacki 2002-11-25 15:36:32 UTC
Radim's measuring:
PIII/800MHz, Linux (2.4.17), 512MB
NetBeans IDE Dev (Build 200211180100)
Java; VM; Vendor      = 1.4.1; Java HotSpot(TM) Client VM 1.4.1-b21;
Sun Microsystems Inc.

opening main menus

File 165, 35, 37, 47
Edit 257, 33, 37, 40
View 852(!), 98 
Project 183, 69
Build 320, 53
Debug 226, 71
Versioning 266, 51
Tools 682, 130
Window 241, 114
Help 290, 69

Comment 7 Petr Nejedly 2002-11-26 11:26:59 UTC
OK, I've changed the Actions.MenuItem implementation to allow faster
initialization and faster redisplay. The speed of the Ttop level menu
is very good now, except the View menu (issue 28912) and first usage.

If you'd like to test it, remove the View->Doc Indices menuitem
first. you should feel the difference.

To the measurement:
I realized that console output skews the results significantly.
Try to hide the console, perform the measurement and then look for the
results. Or disable console output for input events and show only
the event->paint time.
Comment 8 David Simonek 2002-11-27 10:25:56 UTC
I've repreated measurements on new dev build and my numbers for second
and further menu invocations are still the same as before: (in
millisecons):
46, 47, 31, 31, 32, 62, 15, 47, 31, 47
Moreover I got the same numbers regardless whether output console was
minimized or not.
Either I'm not able to measure the difference on Windows with 16ms
resolution or improveent is not measurable.

Comment 9 Petr Nejedly 2003-01-08 12:43:47 UTC
I've improved the first time menu invocation by using
Menu warmup task. All TLMs should be under 100ms even on the first
invocation, except View menu (issue #28912) and Tools (don't know
yet).
Comment 10 _ ttran 2003-02-11 09:29:44 UTC
We should also "warm up" the second level submenus, c.f. Help|Topics
Comment 11 Petr Nejedly 2003-02-11 15:16:43 UTC
Done (For JMenus comming from o.o.awt.MenuBar).
Help sets now fast enough.

Comment 12 David Simonek 2003-02-17 13:31:10 UTC
Raising priority, fast menu is our priority.
Comment 13 Petr Nejedly 2003-02-18 15:47:31 UTC
Done.