Memory leaks in Sirius? [message #1771830] |
Thu, 31 August 2017 07:57 |
mind calm Messages: 57 Registered: July 2017 |
Member |
|
|
HI,
I use Xtext integrate with Sirius to test my model. I found a serious problem: each time i edit my model in Xtext editor, and triggers Sirius to reload model by saving model in Xtext editor, the total memory of my eclipse will be increased.
I use MAT (Memory Analyzer) to analyse the process, and it report 3 Suspects:
Problem Suspect 1:
One instance of "org.eclipse.core.commands.operations.DefaultOperationHistory" loaded by "org.eclipse.core.commands" occupies 65,834,888 (11.91%) bytes. The memory is accumulated in one instance of "org.eclipse.sirius.diagram.ui.internal.edit.parts.DDiagramEditPart" loaded by "org.eclipse.sirius.diagram.ui".
Problem Suspect 2:
One instance of "org.eclipse.emf.workspace.EMFCommandOperation" loaded by "org.eclipse.emf.workspace" occupies 61,916,472 (11.20%) bytes. The memory is accumulated in one instance of "org.eclipse.sirius.diagram.ui.internal.edit.parts.DDiagramEditPart" loaded by "org.eclipse.sirius.diagram.ui".
Problem Suspect 3:
410 instances of "org.eclipse.sirius.diagram.ui.tools.api.figure.SVGWorkspaceImageFigure", loaded by "org.eclipse.sirius.diagram.ui" occupy 243,685,336 (44.10%) bytes.
From suspect 3, i can make sure there must be memory leaks, because i only have 100 elements in my model, there should only have 100 SVGWorkspaceImageFigure instance in memory.
Now the problem is how to fix this issue?
My test enviroment:
Sirius (4.1.3) + Xtext (2.10.0) + Eclipse Neon.3 (4.6.3)
Best regards!
by Keep Mind Calm
|
|
|
Re: Memory leaks in Sirius? [message #1771887 is a reply to message #1771830] |
Thu, 31 August 2017 16:13 |
|
Hi
Thank you for your analysis. Effectively the SVGWorkspaceImageFigure memory print is particularly significant.
We will look at it. I bet we should reproduce it easily with a Sirius modeling project just making a blank modification in the aird file+save with an external editor. Could you test it with yours?
Just a trivial question: I guess your result analysis does not rely on the fact that the garbage collector had passed or not. It is a real leak and not a memory that could vanish with a garbage collector . Right?
Anyway, I invite you to create a bugzilla ideally with a simple reproducible scenario: https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Sirius
Regards
Laurent
Laurent Fasani - Obeo
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
|
|
|
|
Powered by
FUDForum. Page generated in 0.03391 seconds