Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 3711

Summary: PERF: java ui loading: profile (1GEJX4R)
Product: [Eclipse Project] JDT Reporter: Erich Gamma <erich_gamma>
Component: UIAssignee: Eduardo Pereira <eduardo_pereira>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P2    
Version: 2.0   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:

Description Erich Gamma CLA 2001-10-10 22:59:37 EDT
PRODUCT VERSION:
114

EG (5/30/01 9:08:22 PM)
	scenario:
	0) 	self hosting workspace
	1) 	delete workbench.xml so that no other views are open
	2)		open the workbench and it shows up in the resource perspective
	3) 	open the Java perspective and measure where the time is spent.

	summary, most of the time is spent in loading plugins:
	50% when loading the jdt.ui plugin
	40% when loading the plugins referenced from the Java perspective layout:
			- search plugin for the search results view
			- debug plugin for the console view
	The indexer is out of the loop here it spends only 20ms verifying that the index is still up to date.

	We gain some time by not adding the console and search result view to the Java perspective
	initially. However, these views will be used througout a session and adding them to the layout
	gives a reasonable default to the user.

Description of CPU usage for thread main 
         100.0% - 57231 ms - org.eclipse.core.launcher.UIMain.main()
            100.0% - 57231 ms - org.eclipse.core.launcher.Main.run()
               100.0% - 57231 ms - org.eclipse.core.launcher.Main.basicRun()
                  100.0% - 57231 ms - java.lang.reflect.Method.invoke()
                     100.0% - 57231 ms - org.eclipse.core.boot.BootLoader.run()
                        100.0% - 57231 ms - org.eclipse.core.internal.boot.InternalBootLoader.run()
                           100.0% - 57231 ms - org.eclipse.ui.internal.Workbench.run()
                              100.0% - 57231 ms - org.eclipse.ui.internal.Workbench.runEventLoop()
                                 99.93% - 57193 ms - org.eclipse.swt.widgets.Display.readAndDispatch()
                                    98.11% - 56152 ms - org.eclipse.swt.widgets.Display.runDeferredEvents()
                                       98.11% - 56152 ms - org.eclipse.swt.widgets.Widget.notifyListeners()
                                          98.11% - 56152 ms - org.eclipse.swt.widgets.EventTable.sendEvent()
                                             98.11% - 56152 ms - org.eclipse.swt.widgets.TypedListener.handleEvent()
                                                98.11% - 56152 ms - org.eclipse.ui.actions.PerspectiveMenu$1.widgetSelected()
                                                   98.11% - 56152 ms - org.eclipse.ui.actions.OpenPerspectiveMenu.run()
                                                      97.96% - 56067 ms - org.eclipse.ui.actions.OpenPerspectiveMenu.runWithPerspectiveValue()
                                                         97.96% - 56067 ms - org.eclipse.ui.actions.OpenPerspectiveMenu.runInNewPage()
                                                            97.96% - 56067 ms - org.eclipse.ui.internal.WorkbenchWindow.openPage()
                                                               97.96% - 56067 ms - org.eclipse.swt.custom.BusyIndicator.showWhile()
                                                                  97.94% - 56057 ms - org.eclipse.ui.internal.WorkbenchWindow$4.run()
                                                                     97.94% - 56057 ms - org.eclipse.ui.internal.WorkbenchWindow.access$6()
                                                                        97.94% - 56057 ms - org.eclipse.ui.internal.WorkbenchWindow.busyOpenPage()
                                                                           53.97% - 30892 ms - org.eclipse.ui.internal.WorkbenchPage.<init>()
                                                                              53.97% - 30892 ms - org.eclipse.ui.internal.WorkbenchPage.init()
                                                                                 53.94% - 30875 ms - org.eclipse.ui.internal.WorkbenchPage.createPerspective()
                                                                                    53.94% - 30875 ms - org.eclipse.ui.internal.Perspective.<init>()
                                                                                       53.94% - 30875 ms - org.eclipse.ui.internal.Perspective.createPresentation()
                                                                                          53.94% - 30875 ms - org.eclipse.ui.internal.Perspective.loadPredefinedPersp()
                                                                                             36.28% - 20766 ms - org.eclipse.ui.internal.registry.PerspectiveDescriptor.createFactory()
                                                                                             17.66% - 10109 ms - org.eclipse.jdt.internal.ui.JavaPerspectiveFactory.createInitialLayout()
                                                                                 0.02% - 17 ms - org.eclipse.ui.internal.WorkbenchWindow.firePerspectiveActivated()
                                                                           43.9% - 25125 ms - org.eclipse.ui.internal.WorkbenchWindow.setActivePage()
                                                                              43.9% - 25125 ms - org.eclipse.swt.custom.BusyIndicator.showWhile()
                                                                                 43.9% - 25125 ms - org.eclipse.ui.internal.WorkbenchWindow$5.run()
                                                                                    42.04% - 24064 ms - org.eclipse.ui.internal.WorkbenchPage.onActivate()
                                                                                       42.03% - 24059 ms - org.eclipse.ui.internal.Perspective.onActivate()
                                                                                          42.03% - 24059 ms - org.eclipse.ui.internal.PerspectivePresentation.activate()
                                                                                             42.02% - 24054 ms - org.eclipse.ui.internal.PartSashContainer.createControl()
                                                                                                41.23% - 23598 ms - org.eclipse.ui.internal.PartTabFolder.createControl()
                                                                                                   41.2% - 23583 ms - org.eclipse.ui.internal.PartTabFolder.createPartTab()
                                                                                                      41.09% - 23518 ms - org.eclipse.ui.internal.ViewPane.createControl()
                                                                                                         39.21% - 22442 ms - org.eclipse.ui.internal.PartPane.createControl()
                                                                                                            38.9% - 22265 ms - org.eclipse.ui.internal.PartPane.createChildControl()
                                                                                                               38.87% - 22250 ms - org.eclipse.core.runtime.Platform.run()
                                                                                                                  38.87% - 22250 ms - org.eclipse.core.internal.runtime.InternalPlatform.run()
                                                                                                                     38.87% - 22250 ms - org.eclipse.ui.internal.PartPane$2.run()
                                                                                                                        12.5% - 7156 ms - org.eclipse.jdt.internal.ui.packageview.PackageExplorerPart.createPartControl()
                                                                                                                        10.92% - 6254 ms - org.eclipse.debug.internal.ui.ConsoleView.createPartControl()
                                                                                                                        8.1% - 4640 ms - org.eclipse.jdt.internal.ui.typehierarchy.TypeHierarchyViewPart.createPartControl()
                                                                                                                        6.8% - 3893 ms - org.eclipse.search.internal.ui.SearchResultView.createPartControl()
                                                                                                                        0.38% - 221 ms - org.eclipse.ui.views.navigator.ResourceNavigator.createPartControl()
                                                                                                                        0.15% - 86 ms - org.eclipse.ui.views.tasklist.TaskList.createPartControl()
.......
Comment 1 Martin Aeschlimann CLA 2001-10-16 11:12:23 EDT
moved to 'active'
Comment 2 Erich Gamma CLA 2001-11-11 05:26:38 EST
one option would be to only add place holders for search and the console in the 
layout (we already use place holders for the Navigator). This ensures that the 
views show up at reasonable position when they later show up.

If the workbench makes views creatioin more lazy, then there is no need to do 
this.

We should inform VAME that they should do the same for the Ant console.
Comment 3 Eduardo Pereira CLA 2002-05-30 17:17:07 EDT
Marking as dup of bug 14716.
We implemented lazy creation of perspectives and editors but we are not going 
to implement lazy creation of views for 2.0

*** This bug has been marked as a duplicate of 14716 ***