AJC memory requirements and Java 8

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

AJC memory requirements and Java 8

Tim Webster
Hi,

We recently switched a project over to Java 8, including setting AJC compliance level to 1.8.

It seems the compliance level change has affected our builds somewhat, since they are tending to fail with errors like the one below.

Upping the max heap size fixes it (before it was 1024m which you'd think is big enough), and if it's just that 1.8 has a higher memory requirement that is fine, but if not I'm wondering if something else could be wrong (especially since it's a GC overhead error and not heap size).

Anything to worry about?


[ERROR] Failed to execute goal uk.co.aquilauk:aspectj-maven-plugin:1.0:test-compile (default) on project adm-q-desktop: AJC compiler errors:

[ERROR] abort trouble in:

[ERROR] <class name removed>Test -- (OutOfMemoryError) GC overhead limit exceeded

[ERROR] GC overhead limit exceeded

[ERROR] java.lang.OutOfMemoryError: GC overhead limit exceeded

[ERROR] at java.lang.String.substring(String.java:1969)

[ERROR] at org.aspectj.weaver.MemberImpl.signatureToTypes(MemberImpl.java:215)

[ERROR] at org.aspectj.weaver.MemberImpl.<init>(MemberImpl.java:56)

[ERROR] at org.aspectj.weaver.ResolvedMemberImpl.<init>(ResolvedMemberImpl.java:82)

[ERROR] at org.aspectj.weaver.bcel.BcelMethod.<init>(BcelMethod.java:85)

[ERROR] at org.aspectj.weaver.bcel.BcelObjectType.getDeclaredMethods(BcelObjectType.java:291)

[ERROR] at org.aspectj.weaver.ReferenceType.getDeclaredMethods(ReferenceType.java:864)

[ERROR] at org.aspectj.weaver.ResolvedType$MethodGetter.get(ResolvedType.java:234)

[ERROR] at org.aspectj.weaver.ResolvedType$MethodGetter.get(ResolvedType.java:232)

[ERROR] at org.aspectj.weaver.Iterators$4$1.hasNext(Iterators.java:213)

[ERROR] at org.aspectj.weaver.Iterators$4.hasNext(Iterators.java:230)

[ERROR] at org.aspectj.weaver.bcel.BcelWorld.makeJoinPointSignatureForMethodInvocation(BcelWorld.java:665)

[ERROR] at org.aspectj.weaver.bcel.BcelShadow.makeMethodCall(BcelShadow.java:781)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.matchInvokeInstruction(BcelClassWeaver.java:3259)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2905)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2685)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:480)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:100)

[ERROR] at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1697)




_______________________________________________
aspectj-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: AJC memory requirements and Java 8

Andy Clement
I’m not aware of any particular changes that should disturb memory usage too much, other than maybe Java8 just being ‘bigger’ in general and so analysis of types (walking methods, class hierarchies) will have to perhaps explore more stuff.  And although permgen is removed in Java8 and it hasn’t all been moved to the regular heap, there is *some* regular heap impact due to that change.

I guess I’d say increase your heap but keep an eye on it, if you get worried it is something more insidious we can take a look.  My eclipse workspace heaps were 1024m for a while but I have been bumping them up a bit lately.

cheers,
Andy

On Apr 1, 2016, at 8:42 AM, Tim Webster <[hidden email]> wrote:

Hi,

We recently switched a project over to Java 8, including setting AJC compliance level to 1.8.

It seems the compliance level change has affected our builds somewhat, since they are tending to fail with errors like the one below.

Upping the max heap size fixes it (before it was 1024m which you'd think is big enough), and if it's just that 1.8 has a higher memory requirement that is fine, but if not I'm wondering if something else could be wrong (especially since it's a GC overhead error and not heap size).

Anything to worry about?


[ERROR] Failed to execute goal uk.co.aquilauk:aspectj-maven-plugin:1.0:test-compile (default) on project adm-q-desktop: AJC compiler errors:

[ERROR] abort trouble in:

[ERROR] <class name removed>Test -- (OutOfMemoryError) GC overhead limit exceeded

[ERROR] GC overhead limit exceeded

[ERROR] java.lang.OutOfMemoryError: GC overhead limit exceeded

[ERROR] at java.lang.String.substring(String.java:1969)

[ERROR] at org.aspectj.weaver.MemberImpl.signatureToTypes(MemberImpl.java:215)

[ERROR] at org.aspectj.weaver.MemberImpl.<init>(MemberImpl.java:56)

[ERROR] at org.aspectj.weaver.ResolvedMemberImpl.<init>(ResolvedMemberImpl.java:82)

[ERROR] at org.aspectj.weaver.bcel.BcelMethod.<init>(BcelMethod.java:85)

[ERROR] at org.aspectj.weaver.bcel.BcelObjectType.getDeclaredMethods(BcelObjectType.java:291)

[ERROR] at org.aspectj.weaver.ReferenceType.getDeclaredMethods(ReferenceType.java:864)

[ERROR] at org.aspectj.weaver.ResolvedType$MethodGetter.get(ResolvedType.java:234)

[ERROR] at org.aspectj.weaver.ResolvedType$MethodGetter.get(ResolvedType.java:232)

[ERROR] at org.aspectj.weaver.Iterators$4$1.hasNext(Iterators.java:213)

[ERROR] at org.aspectj.weaver.Iterators$4.hasNext(Iterators.java:230)

[ERROR] at org.aspectj.weaver.bcel.BcelWorld.makeJoinPointSignatureForMethodInvocation(BcelWorld.java:665)

[ERROR] at org.aspectj.weaver.bcel.BcelShadow.makeMethodCall(BcelShadow.java:781)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.matchInvokeInstruction(BcelClassWeaver.java:3259)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2905)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2685)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:480)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:100)

[ERROR] at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1697)



_______________________________________________
aspectj-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-users


_______________________________________________
aspectj-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: AJC memory requirements and Java 8

Tim Webster
OK will do - thanks Andy...

On Fri, Apr 1, 2016 at 4:55 PM, Andy Clement <[hidden email]> wrote:
I’m not aware of any particular changes that should disturb memory usage too much, other than maybe Java8 just being ‘bigger’ in general and so analysis of types (walking methods, class hierarchies) will have to perhaps explore more stuff.  And although permgen is removed in Java8 and it hasn’t all been moved to the regular heap, there is *some* regular heap impact due to that change.

I guess I’d say increase your heap but keep an eye on it, if you get worried it is something more insidious we can take a look.  My eclipse workspace heaps were 1024m for a while but I have been bumping them up a bit lately.

cheers,
Andy

On Apr 1, 2016, at 8:42 AM, Tim Webster <[hidden email]> wrote:

Hi,

We recently switched a project over to Java 8, including setting AJC compliance level to 1.8.

It seems the compliance level change has affected our builds somewhat, since they are tending to fail with errors like the one below.

Upping the max heap size fixes it (before it was 1024m which you'd think is big enough), and if it's just that 1.8 has a higher memory requirement that is fine, but if not I'm wondering if something else could be wrong (especially since it's a GC overhead error and not heap size).

Anything to worry about?


[ERROR] Failed to execute goal uk.co.aquilauk:aspectj-maven-plugin:1.0:test-compile (default) on project adm-q-desktop: AJC compiler errors:

[ERROR] abort trouble in:

[ERROR] <class name removed>Test -- (OutOfMemoryError) GC overhead limit exceeded

[ERROR] GC overhead limit exceeded

[ERROR] java.lang.OutOfMemoryError: GC overhead limit exceeded

[ERROR] at java.lang.String.substring(String.java:1969)

[ERROR] at org.aspectj.weaver.MemberImpl.signatureToTypes(MemberImpl.java:215)

[ERROR] at org.aspectj.weaver.MemberImpl.<init>(MemberImpl.java:56)

[ERROR] at org.aspectj.weaver.ResolvedMemberImpl.<init>(ResolvedMemberImpl.java:82)

[ERROR] at org.aspectj.weaver.bcel.BcelMethod.<init>(BcelMethod.java:85)

[ERROR] at org.aspectj.weaver.bcel.BcelObjectType.getDeclaredMethods(BcelObjectType.java:291)

[ERROR] at org.aspectj.weaver.ReferenceType.getDeclaredMethods(ReferenceType.java:864)

[ERROR] at org.aspectj.weaver.ResolvedType$MethodGetter.get(ResolvedType.java:234)

[ERROR] at org.aspectj.weaver.ResolvedType$MethodGetter.get(ResolvedType.java:232)

[ERROR] at org.aspectj.weaver.Iterators$4$1.hasNext(Iterators.java:213)

[ERROR] at org.aspectj.weaver.Iterators$4.hasNext(Iterators.java:230)

[ERROR] at org.aspectj.weaver.bcel.BcelWorld.makeJoinPointSignatureForMethodInvocation(BcelWorld.java:665)

[ERROR] at org.aspectj.weaver.bcel.BcelShadow.makeMethodCall(BcelShadow.java:781)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.matchInvokeInstruction(BcelClassWeaver.java:3259)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2905)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.match(BcelClassWeaver.java:2685)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:480)

[ERROR] at org.aspectj.weaver.bcel.BcelClassWeaver.weave(BcelClassWeaver.java:100)

[ERROR] at org.aspectj.weaver.bcel.BcelWeaver.weave(BcelWeaver.java:1697)



_______________________________________________
aspectj-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-users


_______________________________________________
aspectj-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-users


_______________________________________________
aspectj-users mailing list
[hidden email]
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/aspectj-users
Loading...