Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Java Heap Space error during code generation
Java Heap Space error during code generation [message #664675] Mon, 11 April 2011 15:04 Go to next message
Elhamlaoui Mahmoud is currently offline Elhamlaoui Mahmoud
Messages: 260
Registered: March 2010
Senior Member
Hi,

Im wondering if any one got this problem, when i add some new elements to my gmfgraph/gmfmap, i got the folowing error in my code generation :
Quote:

java.lang.OutOfMemoryError: Java heap space
at org.eclipse.jdt.core.dom.ASTConverter.setQualifiedNameNameAn dSourceRanges(ASTConverter.java:4905)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2349)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2117)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2369)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:1655)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2047)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2044)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:1652)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:1815)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2452)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2561)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2461)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:524)
at org.eclipse.jdt.core.dom.ASTConverter.buildBodyDeclarations( ASTConverter.java:180)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:2709)
at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j ava:1266)
at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(Com pilationUnitResolver.java:289)
at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTPars er.java:1201)
at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java: 801)
at org.eclipse.gmf.internal.common.codegen.OrganizeImportsPostp rocessor.organizeImports(OrganizeImportsPostprocessor.java:1 03)
at org.eclipse.gmf.internal.common.codegen.GeneratorBase.doGene rateJavaClass(GeneratorBase.java:364)
at org.eclipse.gmf.internal.common.codegen.GeneratorBase.doGene rateJavaClass(GeneratorBase.java:334)
at org.eclipse.gmf.codegen.util.Generator.generateVisualIDRegis try(Generator.java:631)
at org.eclipse.gmf.codegen.util.Generator.customRun(Generator.j ava:168)
at org.eclipse.gmf.internal.common.codegen.GeneratorBase$1.run( GeneratorBase.java:486)
at org.eclipse.core.internal.resources.Workspace.run(Workspace. java:1975)
at org.eclipse.core.internal.resources.Workspace.run(Workspace. java:1957)
at org.eclipse.gmf.internal.common.codegen.GeneratorBase.doRun( GeneratorBase.java:483)
at org.eclipse.gmf.internal.common.codegen.GeneratorBase.run(Ge neratorBase.java:90)
at org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTempla tesOperation.run(ExecuteTemplatesOperation.java:226)
at org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTempla tesOperation$1.run(ExecuteTemplatesOperation.java:122)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)




with this config :

Quote:

-startup
plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.1.R 36x_v20100810
-product
org.eclipse.epp.package.jee.product
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vmargs
-XX:PermSize=128M
-XX:MaxPermSize=256M
-Xms1024M
-Xmx1300M



N.B : the size of my gmfgen file is upper than 4MB
any ideas?
Re: Java Heap Space error during code generation [message #664696 is a reply to message #664675] Mon, 11 April 2011 15:38 Go to previous messageGo to next message
Ed Merks is currently offline Ed Merks
Messages: 26137
Registered: July 2009
Senior Member
Your stack seems HUGE. Maybe that's cutting into how much heap is
available.

Elhamlaoui Mahmoud wrote:
> Hi,
>
> Im wondering if any one got this problem, when i add some new
> elements to my gmfgraph/gmfmap, i got the folowing error in my code
> generation :
> Quote:
>> java.lang.OutOfMemoryError: Java heap space
>> at org.eclipse.jdt.core.dom.ASTConverter.setQualifiedNameNameAn
>> dSourceRanges(ASTConverter.java:4905)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2349)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2117)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2369)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:1655)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2047)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2044)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:1652)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:1815)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2452)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2561)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2461)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:524)
>> at org.eclipse.jdt.core.dom.ASTConverter.buildBodyDeclarations(
>> ASTConverter.java:180)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:2709)
>> at org.eclipse.jdt.core.dom.ASTConverter.convert(ASTConverter.j
>> ava:1266)
>> at org.eclipse.jdt.core.dom.CompilationUnitResolver.convert(Com
>> pilationUnitResolver.java:289)
>> at org.eclipse.jdt.core.dom.ASTParser.internalCreateAST(ASTPars
>> er.java:1201)
>> at org.eclipse.jdt.core.dom.ASTParser.createAST(ASTParser.java:
>> 801)
>> at org.eclipse.gmf.internal.common.codegen.OrganizeImportsPostp
>> rocessor.organizeImports(OrganizeImportsPostprocessor.java:1 03)
>> at org.eclipse.gmf.internal.common.codegen.GeneratorBase.doGene
>> rateJavaClass(GeneratorBase.java:364)
>> at org.eclipse.gmf.internal.common.codegen.GeneratorBase.doGene
>> rateJavaClass(GeneratorBase.java:334)
>> at org.eclipse.gmf.codegen.util.Generator.generateVisualIDRegis
>> try(Generator.java:631)
>> at org.eclipse.gmf.codegen.util.Generator.customRun(Generator.j
>> ava:168)
>> at org.eclipse.gmf.internal.common.codegen.GeneratorBase$1.run(
>> GeneratorBase.java:486)
>> at org.eclipse.core.internal.resources.Workspace.run(Workspace.
>> java:1975)
>> at org.eclipse.core.internal.resources.Workspace.run(Workspace.
>> java:1957)
>> at org.eclipse.gmf.internal.common.codegen.GeneratorBase.doRun(
>> GeneratorBase.java:483)
>> at org.eclipse.gmf.internal.common.codegen.GeneratorBase.run(Ge
>> neratorBase.java:90)
>> at org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTempla
>> tesOperation.run(ExecuteTemplatesOperation.java:226)
>> at org.eclipse.gmf.internal.codegen.popup.actions.ExecuteTempla
>> tesOperation$1.run(ExecuteTemplatesOperation.java:122)
>> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
>
>
> with this config :
>
> Quote:
>> -startup
>> plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
>> --launcher.library
>> plugins/org.eclipse.equinox.launcher.win32.win32.x86_1.1.1.R
>> 36x_v20100810
>> -product
>> org.eclipse.epp.package.jee.product
>> --launcher.defaultAction
>> openFile
>> --launcher.XXMaxPermSize
>> 256M
>> -showsplash
>> org.eclipse.platform
>> --launcher.XXMaxPermSize
>> 256m
>> --launcher.defaultAction
>> openFile
>> -vmargs
>> -XX:PermSize=128M
>> -XX:MaxPermSize=256M
>> -Xms1024M
>> -Xmx1300M
>
>
> N.B : the size of my gmfgen file is upper than 4MB any ideas?
Re: Java Heap Space error during code generation [message #664713 is a reply to message #664696] Mon, 11 April 2011 16:47 Go to previous messageGo to next message
Elhamlaoui Mahmoud is currently offline Elhamlaoui Mahmoud
Messages: 260
Registered: March 2010
Senior Member
Hi Ed,

According to this, http://www.eclipse.org/forums/index.php?t=msg&th=164384& amp;start=0&S=7950dad4ccdc06ee56e99622976b74d2 i tried something less than 1G but it diplay an error sooner than before

thanks again
Re: Java Heap Space error during code generation [message #664722 is a reply to message #664713] Mon, 11 April 2011 17:08 Go to previous messageGo to next message
Ed Merks is currently offline Ed Merks
Messages: 26137
Registered: July 2009
Senior Member
My comment was about your huge stack, i.e., -Xms1024M. It can't need
to be that big. And of course you can only make the heap so big. Not
sure if you can make it bigger that 1300M. You've tried?


Elhamlaoui Mahmoud wrote:
> Hi Ed,
>
> According to this,
> http://www.eclipse.org/forums/index.php?t=msg&th=164384& amp;start=0&S=7950dad4ccdc06ee56e99622976b74d2
> i tried something less than 1G but it diplay an error sooner than before
>
> thanks again
Re: Java Heap Space error during code generation [message #664841 is a reply to message #664722] Tue, 12 April 2011 09:19 Go to previous messageGo to next message
Elhamlaoui Mahmoud is currently offline Elhamlaoui Mahmoud
Messages: 260
Registered: March 2010
Senior Member
Hi Ed,

I tried but i the max size that i could make is 1385M otherwise i get a problem in launching eclipse "Failed to create the java Virtual Machine"

thanks a lot
Re: Java Heap Space error during code generation [message #664967 is a reply to message #664841] Tue, 12 April 2011 15:58 Go to previous message
Ed Merks is currently offline Ed Merks
Messages: 26137
Registered: July 2009
Senior Member
All I could suggest is to try to have Eclipse in a state (fewer open
editors and such) where it's not already using so much heap space.

Elhamlaoui Mahmoud wrote:
> Hi Ed,
>
> I tried but i the max size that i could make is 1385M otherwise i get
> a problem in launching eclipse "Failed to create the java Virtual
> Machine"
>
> thanks a lot
Previous Topic:Using Ecorediag Resources Headless
Next Topic:Redraw connections after modification
Goto Forum:
  


Current Time: Thu Oct 23 07:57:53 GMT 2014

Powered by FUDForum. Page generated in 0.01920 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software