Upcoming changes to ClassAnalyzer

Mandy Chung Mandy.Chung at Sun.COM
Wed Nov 4 14:09:43 PST 2009


I spent some time to include the runtime dependencies that cannot be 
determined from the static analysis including Class.forName, service 
providers, and JNI_FindClass calls.  I scanned through most of such 
references in the jdk repository and generated an updated 
jdk7.depconfig.  I use annotations to keep track of these runtime 
dependencies so that incremental investigation and changes can be 
made.   The tool is also also updated:
   http://cr.openjdk.java.net/~mchung/jigsaw/tools/webrev.110409/

I added several annotations in my own jdk7 repository to track these 
runtime dependencies.  The webrev of the current annotated jdk repo is at:
   http://cr.openjdk.java.net/~mchung/jigsaw/annotated_jdk_webrev/

If you run the classanalyzer with -depconfig jdk7.depconfig option,  
dependencies listed in jdk7.depconfig will be added if they are not 
found in the classfile analysis.   Such dependency added by the 
depconfig file will be represented as red color, dotted line in the 
modules.dot file.

The make/classanalyzer.sh doesn't set this option by default.  Some of 
the depconfig dependencies are conditional (e.g. sun.misc.Launcher may 
load sun.net.www.protocol.ftp.Handler) and some may be needed.  So we 
will update the modules.config when a dependency is missed.  For example,
   sun.net.idn.StringPrep  -> sun.net.idn.UCharacterDirection (other) 
@Inline

sun.net.idn.UCharacterDirection was inlined by the compiler.  I have 
fixed modules.config to include that class in the base module.

Mandy



More information about the jigsaw-dev mailing list