Community
Participate
Working Groups
Build Identifier: There are several performance improvements that can be performed quite easily on the MetaModelDescriptorRegistry: 1. getDescriptor(EPackage) and getDescriptor(URI) shall use a precompiled pattern for regexp. 2. Use LinkedHashMap instead of HashMap to keep the descriptor. In case of multiple descriptor the same performance will be obtained at each run. 3. Even if multiple descriptors are defined during a heavy computing user action only one or two descriptors are actually used. If those descriptors are the last in the hash a lot of cpu cycles are wasted. The proposal would be: - each time getDescriptor(T mmDescriptor, IDescriptorFilter filter) is used and the returned descriptor is not the first in the list change the list by moving the found descriptor to the first position. This way the next call of the method, which probably will look for the same descriptor, will execute faster. Reproducible: Always
(In reply to comment #0) Good ideas! I'm ok with all of them, they can be implemented right away. @1. Note precompiled patterns must be used in this - rather non intuitive - way to be effective: return Pattern.compile(descriptor.getEPackageNsURIPattern()).matcher(nsURI).matches()
I might have time to work on this in the July/August.
Resolved
Created attachment 200650 [details] mylyn/context/zip
Mass-closing Resolved tickets