On 26/01/2017 02:15, Mandy Chung wrote:
The ModuleTarget attribute is added to java.base and other JDK modules when
JMOD file is created but it gets dropped when the system modules plugin
reconstitutes the ModuleDescriptor for fast loading. The fix is
straight-forward to add osName/osArch/osVersion if present.
Webrev at:
http://cr.openjdk.java.net/~mchung/jdk9/webrevs/8173381/webrev.00/
The set of modules has to include java.base so if it has all three
properties then there is no need to call the builder methods for the
other modules. That will save a few bytecodes at startup. It's not
critical of course, just a small saving.
Otherwise I think the change looks okay. At some point then the
ModuleTarget class file attribute needs to be re-examined to see if the
values it records are the right set. So it's possible it will change
again. If there are more then I assume we can use one method to emit the
instructions as they are builder method name / value pairs.
-Alan