Community
Participate
Working Groups
I spent some time digging around why builds were taking so long, and pinpointed it to DynamicEClass.getClazz(). I've attached an egl file as an example. When using an IBM JRE 1.6, I get results as follows (all times in milliseconds): Time spent in getClazz(): 1430, total time creating IR: 1692 When switching to Sun 1.6, it's much faster: Time spent in getClazz(): 28, total time creating IR: 306 It looks like the EGL_Location annotation goes through this code, and every element has this annotation, causing the function to be invoked many, many times. This is why I put so many dummy statements in the example file. The more statements you add, the bigger this gap between JREs. This needs to be sped up - building a relatively small project can take a couple minutes.
Created attachment 197651 [details] file demonstrating slow build times
I have fixed this with a simple change to MofLookupDelegate. The code was previously saving the DynamicEClass object that it created for each of the dynamic annotations into Environment.INSTANCE, instead of saving into the current environment.
Verified in latest CVS