Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 81313 Details for
Bug 207648
Speed up weaving option: favor occasional runtime tests
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Implementation Patch
fastWeavingOptionPatch.txt (text/plain), 4.21 KB, created by
Ron Bodkin
on 2007-10-26 19:57:27 EDT
(
hide
)
Description:
Implementation Patch
Filename:
MIME Type:
Creator:
Ron Bodkin
Created:
2007-10-26 19:57:27 EDT
Size:
4.21 KB
patch
obsolete
>Index: src/org/aspectj/weaver/MemberImpl.java >=================================================================== >RCS file: /cvsroot/tools/org.aspectj/modules/weaver/src/org/aspectj/weaver/MemberImpl.java,v >retrieving revision 1.15 >diff -u -r1.15 MemberImpl.java >--- src/org/aspectj/weaver/MemberImpl.java 23 Jan 2007 10:45:34 -0000 1.15 >+++ src/org/aspectj/weaver/MemberImpl.java 26 Oct 2007 23:53:57 -0000 >@@ -507,6 +507,7 @@ > */ > public boolean isCompatibleWith(Member am) { > if (kind != METHOD || am.getKind() != METHOD) return true; >+ if (name.hashCode() != am.getName().hashCode()) return true; // faster than the equality check > if (! name.equals(am.getName())) return true; > if (! equalTypes(getParameterTypes(), am.getParameterTypes())) return true; > return getReturnType().equals(am.getReturnType()); >Index: src/org/aspectj/weaver/World.java >=================================================================== >RCS file: /cvsroot/tools/org.aspectj/modules/weaver/src/org/aspectj/weaver/World.java,v >retrieving revision 1.100 >diff -u -r1.100 World.java >--- src/org/aspectj/weaver/World.java 6 Nov 2006 13:53:12 -0000 1.100 >+++ src/org/aspectj/weaver/World.java 26 Oct 2007 23:53:58 -0000 >@@ -111,6 +111,7 @@ > private boolean shouldPipelineCompilation = true; > protected boolean bcelRepositoryCaching = xsetBCEL_REPOSITORY_CACHING_DEFAULT.equalsIgnoreCase("true"); > private boolean completeBinaryTypes = false; >+ private boolean isFastWeaving = false; > public boolean forDEBUG_structuralChangesCode = false; > public boolean forDEBUG_bridgingCode = false; > >@@ -798,6 +799,8 @@ > public final static String xsetCOMPLETE_BINARY_TYPES = "completeBinaryTypes"; > public final static String xsetCOMPLETE_BINARY_TYPES_DEFAULT = "false"; > public final static String xsetBCEL_REPOSITORY_CACHING_DEFAULT = "true"; >+ public final static String xsetFAST_WEAVING = "fastWeaving"; >+ public final static String xsetFAST_WEAVING_DEFAULT = "true"; > > public boolean isInJava5Mode() { > return behaveInJava5Way; >@@ -1209,6 +1212,8 @@ > s = p.getProperty(xsetDEBUG_BRIDGING,"false"); > forDEBUG_bridgingCode = s.equalsIgnoreCase("true"); > >+ s = p.getProperty(xsetFAST_WEAVING,xsetFAST_WEAVING_DEFAULT); >+ isFastWeaving = s.equalsIgnoreCase("true"); > } > checkedAdvancedConfiguration=true; > } >@@ -1250,4 +1255,8 @@ > public boolean isASMAround() { > return isASMAround; > } >+ >+ public boolean isFastWeaving() { >+ return isFastWeaving; >+ } > } >\ No newline at end of file >Index: src/org/aspectj/weaver/ReferenceType.java >=================================================================== >RCS file: /cvsroot/tools/org.aspectj/modules/weaver/src/org/aspectj/weaver/ReferenceType.java,v >retrieving revision 1.51 >diff -u -r1.51 ReferenceType.java >--- src/org/aspectj/weaver/ReferenceType.java 7 Feb 2007 09:13:13 -0000 1.51 >+++ src/org/aspectj/weaver/ReferenceType.java 26 Oct 2007 23:53:57 -0000 >@@ -217,6 +217,9 @@ > if (this.isFinal() || other.isFinal()) { > return false; > } >+ if (world.isFastWeaving()) >+ return true; // prefer occasional instanceof tests to 10% weaving overhead >+ > // ??? needs to be Methods, not just declared methods? JLS 5.5 unclear > ResolvedMember[] a = getDeclaredMethods(); > ResolvedMember[] b = other.getDeclaredMethods(); //??? is this cast always safe >@@ -343,8 +346,7 @@ > if (other.isTypeVariableReference()) { > TypeVariableReferenceType otherType = (TypeVariableReferenceType) other; > if (this instanceof TypeVariableReference) { >- return ((TypeVariableReference)this).getTypeVariable().canBeBoundTo(otherType.getTypeVariable().getFirstBound().resolve(world));// pr171952 >-// return ((TypeVariableReference)this).getTypeVariable()==otherType.getTypeVariable(); >+ return ((TypeVariableReference)this).getTypeVariable()==otherType.getTypeVariable(); > } else { > // FIXME asc should this say canBeBoundTo?? > return this.isAssignableFrom(otherType.getTypeVariable().getFirstBound().resolve(world));
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 207648
: 81313