Community
Participate
Working Groups
Verifying results for build I20090331-0901, it appears that there's a regression on 'ObjectContributionsPerformance#testObjectContributions:limited selection, limited contributors()' test. This test is currently commented but for a regression between 3.1 and 3.2. So, this comment must either be removed and the regression investigated or updated to explain the difference between 3.4 and 3.5... Looking at history, it seems that the regression got introduce with build I20090120-0920...
The cause of the slowdown appears to be the change made in the bug 231611. The test populates a popup menu which includes "standard" menu items matching URI "popup:org.eclipse.ui.popup.any". In 3.4 that contained only one menu item ("org.eclipse.debug.ui"), in 3.5 the new menu was added in the "org.eclipse.ui.ide.application". The call stack that leads to the slowdown is: WorkbenchMenuService.addContributionsToManager() line: 663 WorkbenchMenuService.populateContributionManager() line: 656 SlaveMenuService.populateContributionManager() line: 203 SlaveMenuService.populateContributionManager() line: 76 PopupMenuExtender.addMenuContributions(IMenuManager) line: 355 PopupMenuExtender.menuAboutToShow(IMenuManager) line: 333 ObjectContributionTest.assertPopupMenus() line: 400 As a result, the #addContributionsToManager() method has two factories in 3.5 and only one factory in 3.4. The test framework runs confirm this hypothesis. For my computer: - CPU time: current in 3.5 is 2.48sec; went to 2.24sec with menu removed (the 3.4 baseline is 2.22sec) - Elapsed time: current 3.5 is 1.61sec; went to 1.44sec with menu removed (the 3.4 baseline is 1.41sec) I am not sure if there is a good way to isolate this test from the "popup:org.eclipse.ui.popup.any" contributions. The test uses an active workbench part (which happens to be an outline view) to populate the pop-up.
We should either add a comment to the test, make the test more stable against changes like the one found by Oleg, or optimize the regression away even if it means optimizing something else.
popup:...any has the effect of being contributed to any popup menu registered with getSite().registerContextMenu(*). I'm not sure of a way to isolate an objectContributionTest without making it more artificial ... i.e. slicing code out of PopupMenuExtender or providing a testing "don't go through IMenuService code" hook. PW
Created attachment 134431 [details] Patch to change description The test measures the time it takes a pop-up menu to show up. Due to the change to bug 231611 the pop-up menu now has 3 items while in 3.4 it used to have 2 items.
Released for I20090511-2000 PW
Verified for 3.5RC1 using I20090512-2000 results (comment has been updated)