In jtreg mainline repo, we recently integrated CODETOOLS-7904122. That change was done to prevent a warning message that jasm compilation writes out if the jasm file being compiled doesn't explicitly contain a class file version. The warning looked like:
> mexit02a.jasm (24:19) Warning: Class file version not specified in file or by -cv parameter. Defaulting to version "45:3"
In the fix forCODETOOLS-7904122, in order to prevent this warning, in jtreg we explicitly passed the class file version to use if none is specified in the jasm file being compiled. We decided to use 52.0 (Java 8) as the default version to compile these jasm files.
It turns out that the JDK repo has several jasm files without explicit class file versions and those when compiled with 52.0 version cause test failures because for this version of the bytecode, the classfile verifier expects stackmap table. These jasm files have none.
To address this, jtreg should explicitly pass -cv value of 45.3 (the version that asmtools would have defaulted to), to prevent this failure as well as to prevent the warning from jasm if no -cv is passed.
> mexit02a.jasm (24:19) Warning: Class file version not specified in file or by -cv parameter. Defaulting to version "45:3"
In the fix for
It turns out that the JDK repo has several jasm files without explicit class file versions and those when compiled with 52.0 version cause test failures because for this version of the bytecode, the classfile verifier expects stackmap table. These jasm files have none.
To address this, jtreg should explicitly pass -cv value of 45.3 (the version that asmtools would have defaulted to), to prevent this failure as well as to prevent the warning from jasm if no -cv is passed.
- caused by
-
CODETOOLS-7904122 Compilation of jasm files leads to class file version warning
-
- Resolved
-
- links to
-
Commit(master)
openjdk/jtreg/a3b1279c
-
Review(master)
openjdk/jtreg/309