-
Sub-task
-
Resolution: Unresolved
-
P3
-
None
-
None
The team would benefit quite a bit from having a smart class file diff tool.
Background and motivation:
WLS patching process recently hit a snag where once developers start using lambdas there is no longer a guarantee that unchanged source files will lead to identical .class files, because the javac compiler might reorder some parts of the .class file depending on when type information is available. This leads to many more jars and classes being spuriously tagged as necessary for a given patch. This appears to be caused byJDK-8067422.
One example that leads to the situation is in one case, the BootstrapMethods attribute was written right after the constant pool, and in another, later in the file.
Better tools for comparing classfiles for "equivalence" would be desirable no matter what (e.g., "equivalent modulo alpha-renumbering of CP entries.").
Ideally, that tool, written in Java (of course), would be a first class tool that would compare class files, and jar files, then report their degree of equivalence.
Background and motivation:
WLS patching process recently hit a snag where once developers start using lambdas there is no longer a guarantee that unchanged source files will lead to identical .class files, because the javac compiler might reorder some parts of the .class file depending on when type information is available. This leads to many more jars and classes being spuriously tagged as necessary for a given patch. This appears to be caused by
One example that leads to the situation is in one case, the BootstrapMethods attribute was written right after the constant pool, and in another, later in the file.
Better tools for comparing classfiles for "equivalence" would be desirable no matter what (e.g., "equivalent modulo alpha-renumbering of CP entries.").
Ideally, that tool, written in Java (of course), would be a first class tool that would compare class files, and jar files, then report their degree of equivalence.