Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [papyrus-rt-dev] Performance Regressions on Oxygen

I don’t think that pushing the responsibility for performance onto the user via preferences is the answer.

Cheers,

Christian

On May 18, 2017, 10:48 -0400, Peter Cigéhn <peter.cigehn@xxxxxxxxx>, wrote:
Hi,

When you are "speaking of the devil"... ;-)

This bug was just written for Papyrus: https://bugs.eclipse.org/bugs/show_bug.cgi?id=516893

/Peter Cigéhn

On 18 May 2017 at 15:24, Peter Cigéhn <peter.cigehn@xxxxxxxxx> wrote:
Hi,

This feels consistent with what I am seeing when using Papyrus-RT. It is sometimes painfully slow, and I really have to keep my pace down when using the tool. I have also enabled the UI responsiveness monitoring (Preferences > General > UI Responsiveness Monitoring and checked "Detect periods of unresponsive UI" and I get *lots* of loggings in the error log related to unresponsive UI. I can see freeze periods of up to 20, and even up to 38(!), seconds when performing certain operations, e.g. deleting a model element (in the specific scenario when emptying the code snippet view for example).

And I don't think that it is only the new architecture framework that is the cause of these performance regressions. I have a bad feeling about the new internationalization feature as well (which I raised my concern about here for example). What I can see also from the UI freezes logged in the error log, and the sample stack traces they provide is that I often get stack traces similar to the following, where I can see calls to UMLInternationalizationKeyResolver.createInternationalizationEntryByKey.

This specific trace was the freezing happening when opening a model.

org.eclipse.ui.monitoring
Info
Thu May 18 15:15:36 CEST 2017
Sample at 15:15:34.346 (+1,313s)
Thread 'main' tid=1 (RUNNABLE)

Stack Trace
at org.eclipse.uml2.common.util.DerivedEObjectEList$DerivedListIterator.prepareNext(DerivedEObjectEList.java:95)
at org.eclipse.uml2.common.util.DerivedEObjectEList$DerivedListIterator.hasNext(DerivedEObjectEList.java:151)
at org.eclipse.uml2.common.util.DerivedEObjectEList$DerivedListIterator.next(DerivedEObjectEList.java:160)
at org.eclipse.papyrus.uml.tools.utils.NameResolutionUtils.getNamedElements(NameResolutionUtils.java:168)
at org.eclipse.papyrus.uml.tools.utils.NameResolutionUtils.getNamedElements(NameResolutionUtils.java:78)
at org.eclipse.papyrus.uml.tools.utils.NameResolutionUtils.getNamedElements(NameResolutionUtils.java:56)
at org.eclipse.papyrus.uml.internationalization.utils.UMLInternationalizationKeyResolver.createInternationalizationEntryByKey(UMLInternationalizationKeyResolver.java:92)
at org.eclipse.papyrus.infra.internationalization.resource.InternationalizationResource.load(InternationalizationResource.java:111)
at org.eclipse.papyrus.infra.internationalization.modelresource.InternationalizationModelResource.loadResource(InternationalizationModelResource.java:412)
at org.eclipse.papyrus.infra.internationalization.modelresource.InternationalizationModelResource.loadModel(InternationalizationModelResource.java:217)
at org.eclipse.papyrus.infra.internationalization.modelresource.InternationalizationModelResource.loadModel(InternationalizationModelResource.java:193)
at org.eclipse.papyrus.infra.internationalization.modelsnippet.PropertiesAdjunctResourceModelSnippet.loadResource(PropertiesAdjunctResourceModelSnippet.java:59)
at org.eclipse.papyrus.infra.internationalization.modelsnippet.PropertiesAdjunctResourceModelSnippet.loadAdjunctResource(PropertiesAdjunctResourceModelSnippet.java:101)
at org.eclipse.papyrus.infra.internationalization.modelsnippet.PropertiesAdjunctResourceModelSnippet$1.handleResourceLoaded(PropertiesAdjunctResourceModelSnippet.java:78)
at org.eclipse.papyrus.infra.core.resource.ResourceAdapter.handleResourceLoaded0(ResourceAdapter.java:236)
at org.eclipse.papyrus.infra.core.resource.ResourceAdapter.notifyChanged(ResourceAdapter.java:91)
at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:374)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1538)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1297)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:259)
at org.eclipse.papyrus.infra.core.resource.ModelSet.demandLoad(ModelSet.java:378)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:406)
at org.eclipse.papyrus.infra.core.resource.ModelSet.getResource(ModelSet.java:218)
at org.eclipse.papyrus.infra.services.resourceloading.impl.ProxyManager.getEObjectFromStrategy(ProxyManager.java:132)
at org.eclipse.papyrus.infra.services.resourceloading.OnDemandLoadingModelSet.getEObject(OnDemandLoadingModelSet.java:92)
at org.eclipse.emf.ecore.util.EcoreUtil.resolve(EcoreUtil.java:201)
at org.eclipse.emf.ecore.util.EcoreUtil.resolve(EcoreUtil.java:261)
at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eResolveProxy(BasicEObjectImpl.java:1477)
at org.eclipse.uml2.uml.internal.impl.PackageImportImpl.getImportedPackage(PackageImportImpl.java:240)
at org.eclipse.uml2.uml.internal.operations.NamespaceOperations.getImportedMembers(NamespaceOperations.java:373)
at org.eclipse.uml2.uml.internal.impl.NamespaceImpl.getImportedMembers(NamespaceImpl.java:396)
at org.eclipse.uml2.uml.internal.impl.ProfileImpl.eIsSet(ProfileImpl.java:852)
at org.eclipse.uml2.common.util.DerivedEObjectEList$DerivedListIterator.prepareNext(DerivedEObjectEList.java:100)
at org.eclipse.uml2.common.util.DerivedEObjectEList$DerivedListIterator.hasNext(DerivedEObjectEList.java:151)
at org.eclipse.uml2.common.util.DerivedEObjectEList$DerivedListIterator.next(DerivedEObjectEList.java:160)
at org.eclipse.papyrus.uml.tools.utils.NameResolutionUtils.getNamedElements(NameResolutionUtils.java:168)
at org.eclipse.papyrus.uml.tools.utils.NameResolutionUtils.getNamedElements(NameResolutionUtils.java:78)
at org.eclipse.papyrus.uml.tools.utils.NameResolutionUtils.getNamedElements(NameResolutionUtils.java:56)
at org.eclipse.papyrus.uml.internationalization.utils.UMLInternationalizationKeyResolver.createInternationalizationEntryByKey(UMLInternationalizationKeyResolver.java:92)
at org.eclipse.papyrus.infra.internationalization.resource.InternationalizationResource.load(InternationalizationResource.java:111)
at org.eclipse.papyrus.infra.internationalization.modelresource.InternationalizationModelResource.loadResource(InternationalizationModelResource.java:412)
at org.eclipse.papyrus.infra.internationalization.modelresource.InternationalizationModelResource.loadModel(InternationalizationModelResource.java:217)
at org.eclipse.papyrus.infra.internationalization.modelresource.InternationalizationModelResource.loadModel(InternationalizationModelResource.java:193)
at org.eclipse.papyrus.infra.internationalization.modelsnippet.PropertiesAdjunctResourceModelSnippet.loadResource(PropertiesAdjunctResourceModelSnippet.java:59)
at org.eclipse.papyrus.infra.internationalization.modelsnippet.PropertiesAdjunctResourceModelSnippet.loadAdjunctResource(PropertiesAdjunctResourceModelSnippet.java:101)
at org.eclipse.papyrus.infra.internationalization.modelsnippet.PropertiesAdjunctResourceModelSnippet$1.handleResourceLoaded(PropertiesAdjunctResourceModelSnippet.java:78)
at org.eclipse.papyrus.infra.core.resource.ResourceAdapter.handleResourceLoaded0(ResourceAdapter.java:236)
at org.eclipse.papyrus.infra.core.resource.ResourceAdapter.notifyChanged(ResourceAdapter.java:91)
at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:374)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1538)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.getPackageForURI(XMLHandler.java:2579)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.getFactoryForPrefix(XMLHandler.java:2458)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.createObjectByType(XMLHandler.java:1335)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.createTopObject(XMLHandler.java:1504)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.processElement(XMLHandler.java:1026)
at org.eclipse.emf.ecore.xmi.impl.XMIHandler.processElement(XMIHandler.java:82)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.startElement(XMLHandler.java:1008)
at org.eclipse.emf.ecore.xmi.impl.XMLHandler.startElement(XMLHandler.java:719)
at org.eclipse.emf.ecore.xmi.impl.XMIHandler.startElement(XMIHandler.java:190)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source)
at org.eclipse.emf.ecore.xmi.impl.XMLLoadImpl.load(XMLLoadImpl.java:175)
at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doLoad(XMLResourceImpl.java:261)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1518)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1297)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:259)
at org.eclipse.papyrus.infra.core.resource.ModelSet.demandLoad(ModelSet.java:378)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:406)
at org.eclipse.papyrus.infra.core.resource.ModelSet.getResource(ModelSet.java:218)
at org.eclipse.papyrus.infra.services.resourceloading.impl.ProxyManager.getEObjectFromStrategy(ProxyManager.java:132)
at org.eclipse.papyrus.infra.services.resourceloading.OnDemandLoadingModelSet.getEObject(OnDemandLoadingModelSet.java:92)
at org.eclipse.emf.ecore.util.EcoreUtil.resolve(EcoreUtil.java:201)
at org.eclipse.emf.ecore.util.EcoreUtil.resolve(EcoreUtil.java:261)
at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eResolveProxy(BasicEObjectImpl.java:1477)
at org.eclipse.uml2.uml.internal.impl.ProfileApplicationImpl.getAppliedProfile(ProfileApplicationImpl.java:185)
at org.eclipse.uml2.uml.internal.operations.PackageOperations.getAppliedProfiles(PackageOperations.java:947)
at org.eclipse.uml2.uml.internal.operations.PackageOperations.getAppliedProfiles(PackageOperations.java:968)
at org.eclipse.uml2.uml.internal.impl.PackageImpl.getAppliedProfiles(PackageImpl.java:1175)
at org.eclipse.papyrus.uml.decoratormodel.helper.DecoratorModelUtils.hasExternalizationProfile(DecoratorModelUtils.java:574)
at org.eclipse.papyrus.uml.decoratormodel.helper.DecoratorModelUtils.isDecoratorModel(DecoratorModelUtils.java:687)
at org.eclipse.papyrus.uml.decoratormodel.helper.DecoratorModelUtils.isDecoratorModel(DecoratorModelUtils.java:705)
at org.eclipse.papyrus.uml.decoratormodel.internal.ui.providers.AvailableDecoratorModelsSnippet.handleResourceLoaded(AvailableDecoratorModelsSnippet.java:92)
at org.eclipse.papyrus.infra.core.resource.ResourceAdapter.handleResourceLoaded0(ResourceAdapter.java:236)
at org.eclipse.papyrus.infra.core.resource.ResourceAdapter.notifyChanged(ResourceAdapter.java:91)
at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:374)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1538)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1297)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:259)
at org.eclipse.papyrus.infra.core.resource.ModelSet.demandLoad(ModelSet.java:378)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:406)
at org.eclipse.papyrus.infra.core.resource.ModelSet.getResource(ModelSet.java:218)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$ResourceLocator.basicGetResource(ResourceSetImpl.java:751)
at org.eclipse.papyrus.infra.emf.resource.ShardResourceLocator.getResource(ShardResourceLocator.java:107)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:352)
at org.eclipse.papyrus.infra.core.resource.ModelSet.getResource(ModelSet.java:218)
at org.eclipse.papyrusrt.umlrt.core.internal.defaultlanguage.DefaultLanguageService.loadResource(DefaultLanguageService.java:398)
at org.eclipse.papyrusrt.umlrt.core.internal.defaultlanguage.DefaultLanguageService.loadDefaultLanguageLibrary(DefaultLanguageService.java:367)
at org.eclipse.papyrusrt.umlrt.core.internal.defaultlanguage.DefaultLanguageService.initLanguage(DefaultLanguageService.java:431)
at org.eclipse.papyrusrt.umlrt.core.internal.defaultlanguage.DefaultLanguageService.startService(DefaultLanguageService.java:180)
at org.eclipse.papyrus.infra.core.services.internal.ServiceEntry.startService(ServiceEntry.java:152)
at org.eclipse.papyrus.infra.core.services.internal.StartStartupEntry.startService(StartStartupEntry.java:81)
at org.eclipse.papyrus.infra.core.services.ServicesRegistry.startServices(ServicesRegistry.java:1020)
at org.eclipse.papyrus.infra.core.services.ServicesRegistry.startRegistry(ServicesRegistry.java:488)
at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.loadModelAndServices(CoreMultiDiagramEditor.java:615)
at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.initContents(CoreMultiDiagramEditor.java:936)
at org.eclipse.papyrus.infra.ui.editor.CoreMultiDiagramEditor.init(CoreMultiDiagramEditor.java:483)
at org.eclipse.ui.internal.EditorReference.initialize(EditorReference.java:362)
at org.eclipse.ui.internal.e4.compatibility.CompatibilityPart.create(CompatibilityPart.java:333)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:55)
at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:990)
at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:955)
at org.eclipse.e4.core.internal.di.InjectorImpl.inject(InjectorImpl.java:124)
at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:399)
at org.eclipse.e4.core.internal.di.InjectorImpl.make(InjectorImpl.java:318)
at org.eclipse.e4.core.contexts.ContextInjectionFactory.make(ContextInjectionFactory.java:162)
at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.createFromBundle(ReflectionContributionFactory.java:105)
at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.doCreate(ReflectionContributionFactory.java:74)
at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.create(ReflectionContributionFactory.java:56)
at org.eclipse.e4.ui.workbench.renderers.swt.ContributedPartRenderer.createWidget(ContributedPartRenderer.java:129)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createWidget(PartRenderingEngine.java:987)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:663)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.safeCreateGui(PartRenderingEngine.java:769)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.access$0(PartRenderingEngine.java:740)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$2.run(PartRenderingEngine.java:734)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.createGui(PartRenderingEngine.java:718)
at org.eclipse.e4.ui.workbench.renderers.swt.StackRenderer.showTab(StackRenderer.java:1289)
at org.eclipse.e4.ui.workbench.renderers.swt.LazyStackRenderer.lambda$0(LazyStackRenderer.java:68)
at org.eclipse.e4.ui.workbench.renderers.swt.LazyStackRenderer$$Lambda$140/1194550829.handleEvent(Unknown Source)
at org.eclipse.e4.ui.services.internal.events.UIEventHandler$1.run(UIEventHandler.java:40)
at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:233)
at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:144)
at org.eclipse.swt.widgets.Display.syncExec(Display.java:4892)
at org.eclipse.e4.ui.internal.workbench.swt.E4Application$1.syncExec(E4Application.java:212)
at org.eclipse.e4.ui.services.internal.events.UIEventHandler.handleEvent(UIEventHandler.java:36)
at org.eclipse.equinox.internal.event.EventHandlerWrapper.handleEvent(EventHandlerWrapper.java:201)
at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:197)
at org.eclipse.equinox.internal.event.EventHandlerTracker.dispatchEvent(EventHandlerTracker.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.ListenerQueue.dispatchEventSynchronous(ListenerQueue.java:148)
at org.eclipse.equinox.internal.event.EventAdminImpl.dispatchEvent(EventAdminImpl.java:135)
at org.eclipse.equinox.internal.event.EventAdminImpl.sendEvent(EventAdminImpl.java:78)
at org.eclipse.equinox.internal.event.EventComponent.sendEvent(EventComponent.java:39)
at org.eclipse.e4.ui.services.internal.events.EventBroker.send(EventBroker.java:52)
at org.eclipse.e4.ui.internal.workbench.UIEventPublisher.notifyChanged(UIEventPublisher.java:60)
at org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify(BasicNotifierImpl.java:374)
at org.eclipse.e4.ui.model.application.ui.impl.ElementContainerImpl.setSelectedElement(ElementContainerImpl.java:173)
at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.showElementInWindow(ModelServiceImpl.java:620)
at org.eclipse.e4.ui.internal.workbench.ModelServiceImpl.bringToTop(ModelServiceImpl.java:584)
at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.delegateBringToTop(PartServiceImpl.java:768)
at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.bringToTop(PartServiceImpl.java:401)
at org.eclipse.e4.ui.internal.workbench.PartServiceImpl.showPart(PartServiceImpl.java:1187)
at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:3261)
at org.eclipse.ui.internal.WorkbenchPage.access$25(WorkbenchPage.java:3176)
at org.eclipse.ui.internal.WorkbenchPage$10.run(WorkbenchPage.java:3158)
at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:70)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:3153)
at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:3117)
at org.eclipse.papyrus.infra.onefile.internal.ui.providers.PapyrusModelActionProvider$1.run(PapyrusModelActionProvider.java:158)
at org.eclipse.ui.actions.RetargetAction.run(RetargetAction.java:216)
at org.eclipse.ui.navigator.CommonNavigatorManager$2.open(CommonNavigatorManager.java:191)
at org.eclipse.ui.OpenAndLinkWithEditorHelper$InternalListener.open(OpenAndLinkWithEditorHelper.java:46)
at org.eclipse.jface.viewers.StructuredViewer$2.run(StructuredViewer.java:851)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.ui.internal.JFaceUtil.lambda$0(JFaceUtil.java:44)
at org.eclipse.ui.internal.JFaceUtil$$Lambda$8/921640293.run(Unknown Source)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:173)
at org.eclipse.jface.viewers.StructuredViewer.fireOpen(StructuredViewer.java:848)
at org.eclipse.jface.viewers.StructuredViewer.handleOpen(StructuredViewer.java:1163)
at org.eclipse.ui.navigator.CommonViewer.handleOpen(CommonViewer.java:451)
at org.eclipse.jface.viewers.StructuredViewer$$Lambda$221/656990981.handleOpen(Unknown Source)
at org.eclipse.jface.util.OpenStrategy.fireOpenEvent(OpenStrategy.java:273)
at org.eclipse.jface.util.OpenStrategy.access$2(OpenStrategy.java:268)
at org.eclipse.jface.util.OpenStrategy$1.handleEvent(OpenStrategy.java:308)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:86)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:4431)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1079)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4241)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3820)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1145)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1034)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:153)
at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:680)
at org.eclipse.ui.internal.Workbench$$Lambda$13/1672070753.run(Unknown Source)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:594)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:138)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:653)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:590)
at org.eclipse.equinox.launcher.Main.run(Main.java:1499)

Personally I would prefer if the internationalization was by default was switched off, and that it did not cause any overhead at all when disabled for a model. Only models that actually have it enabled should get a performance hit from it.

/Peter Cigéhn

On 17 May 2017 at 23:10, Christian Damus <give.a.damus@xxxxxxxxx> wrote:
Hi, again,

Just a quick update:  simply changing the cross-reference adapter attached by the EMFHelper.getUsages() method from one that proactively resolves proxies to one that doesn’t reduces a typical execution time of the Common Diagram Tests suite from 563 seconds to 363 seconds and reduces the typical number of resources loaded by the initialization of the editor test fixture (before a test actually starts) from 55 to 10.

I still need to see, though, why this utility API isn’t finding the CacheAdapter already in place and whether our test environment can make sure that it does.  And also whether the typical workflows for Papyrus-RT users will be liable to run into this problem or not.  In any case, the solution is not to tweak the cross-reference adapter attached by the EMFHelper utility because when the CacheAdapter is inevitably attached later, then the adapter attached by the EMFHelper will be entirely redundant, consuming memory and wasting time on notifications.

Cheers,

Christian

On May 17, 2017, 16:34 -0400, Christian Damus <give.a.damus@xxxxxxxxx>, wrote:
Hi, Team,

In comment 75 of bug 514322, Peter mentioned perceiving performance regression since the adoption of the Oxygen substrate.

I don’t have any impression of the performance of Papyrus-RT for users, but you can see in the execution of the JUnit test suites that we have a severe performance regression on Oxygen, at least in the tests.  They run painfully slowly in comparison to Neon.

I've done some preliminary profiling and one thing in particular jumps out at me as a possible significant contributor:  the new Architecture Framework.  25% of the JUnit execution time now is spent in loading EMF resources.  It looks like this is caused by a cross-reference adapter resolving all proxies on initial loading of a diagram notation file which, by referencing an Architecture resource for the viewpoint in the diagram prototype style, loads everything reachable from that architecture resource.  And unlike Neon, everything now is connected to this Architecture model:
  • element-types configuration models
  • properties view contexts (potentially hordes of XWT files)
  • palettes
  • everything else
IMHO, this is a fundamental flaw in the nature of the link between our user models and our tooling models, and possibly between the various tooling models.  I suggest that the notation resource should not EMF-wise cross-reference an architecture/viewpoint model, but should identify architectures/viewpoints/prototypes by ID.  The tooling resources are not user data; they are not models that should be loaded and edited in the same context as user models.  Or perhaps, if we want to use EMF-ish references, then our resource set implementation should resolve them to shared instances of the tooling resources in their own resource-sets (but I would worry about leaking cross-reference adapters).  In any case, the tooling resources are meta-data for the definition of the tool's behaviour.  They should only be loaded into a single resource-set for each framework, which for the most part is already the case:  the element-types registry loads all of the configuration models into its resource set; the properties view framework loads contexts and XWTs into its resource set; etc.  So, every time that these tooling models are loaded into a Papyrus Editor's model-set (again in every editor) is entirely redundant.

I think this should be fixed before Oxygen release, and it all starts from the notation model's prototype style.  I don't know (yet) how much this actually contributes to the performance regression, and I don't know yet whether the same problem can happen in the editor in a Papyrus workbench (I don't see the same aggressive resource loading there), but I don't think it makes sense that any of these tooling models should be loaded in every editor's model-set.

I've traced the problem in the JUnits to a model-set IModel for internalization support that triggers a call to the EMFHelper.getUsages() API before the UML2 CacheAdapter is installed, so it attaches a particularly aggressive (virulent) cross-reference adapter that loads the entire universe of reachable resources:

    ...
    EMFHelper.getUsages(EObject) line: 53
    ProxyModificationTrackingAdapter.setReferencingResourcesAsModified(EObject) line: 144
    ProxyModificationTrackingAdapter.notifyChanged(Notification) line: 126
    XMIResourceImpl(BasicNotifierImpl).eNotify(Notification) line: 374
    ResourceImpl$ContentsEList<E>(NotifyingListImpl<E>).dispatchNotification(Notification) line: 261
    ResourceImpl$ContentsEList<E>(NotifyingListImpl<E>).addUnique(E) line: 294
    ResourceImpl$ContentsEList<E>(AbstractEList<E>).add(E) line: 305
    AddToResourceCommand.doExecuteWithResult(IProgressMonitor, IAdaptable) line: 66
    AddToResourceCommand(AbstractTransactionalCommand).doExecute(IProgressMonitor, IAdaptable) line: 247
    AddToResourceCommand(AbstractEMFOperation).execute(IProgressMonitor, IAdaptable) line: 150
    GMFtoEMFCommandWrapper.execute() line: 121
    InternationalizationPreferenceModel.intantiateTemplate(URI) line: 324
    InternationalizationPreferenceModel.createModel(URI) line: 289
    InternationalizationPreferenceModel.loadModel(URI) line: 225
    OnDemandLoadingModelSet(ModelSet).loadModels(URI) line: 582
    ...
    
This results in the following additional resources being loaded in every editor of every individual test by resolving all references coming out of the Architecture Model resources:
  • 2  architecture model resources
  • 21 element-types configuration model resources
  • 1  palette configuration model resource
  • 6  redundant copies of statically registered Ecore EPackages (Ecore, GMF Notation, UML, UML Primitive Types, UML Standard Profile, UML-RT).  This looks like the wrong kind of URIs used for metadata references in the tooling models (platform:/plugin URIs instead of the registered namespace URIs)
  • 2  properties view context resources
  • 2  properties view environment (XWT metadata) resources
  • 5  XWT resources (at least)
I’m going to see whether I can fix the EMFHelper utility to use a less aggressive cross-referencer, or somehow tweak the test environment to ensure that the CacheAdapter is ready before this utility is called.  But I’m concerned that these architecture models are leaking metadata into user-land unnecessarily and that it can lead to scaling issues as we add more and more tooling models.  I hope at least to be able to get the tests running more swiftly again by the end of the day tomorrow.

Cheers,

Christian

_______________________________________________
papyrus-rt-dev mailing list
papyrus-rt-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/papyrus-rt-dev



_______________________________________________
papyrus-rt-dev mailing list
papyrus-rt-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/papyrus-rt-dev

Back to the top