8247536: Support for pre-generated java.lang.invoke classes in CDS static archive #193
This patch is reorganized after 8252725, which is separated from this patch to refactor jlink glugin code. The previous webrev with hg can be found at: http://cr.openjdk.java.net/~minqi/2020/8247536/webrev-05. With 8252725 integrated, the regeneration of holder classes is simply to call the new added GenerateJLIClassesHelper.cdsGenerateHolderClasses function.
The text was updated successfully, but these errors were encountered:
@yminqi The following labels will be automatically applied to this pull request:
When this pull request is ready to be reviewed, an RFR email will be sent to the corresponding mailing lists. If you would like to change these labels, use the
generateHolderClasses should never return null and so line 371-377 can
379???????????? Object ret_array = new Object[size * 2];
Rename `ret_array` to retArray to follow the naming convention using camel case.
This should be cached in the caller who checks if -XX:+DumpLoadedClassList
Since there are many CDS-related methods, I think it's time to introduce
I suggest to add CDS:logTraceResolve(String line) method that
493 * Output to DumpLoadedClassList, format is simimar to LF_RESOLVE
Should it say @see java.lang.invoke.GenerateJLIClassesHelper::traceLambdaForm
On 9/15/20 12:15 PM, Yumin Qi wrote:
Will change access to 'private'
Will drop the check and add Objects.requireNonNull(traces).
Created a separate issue https://bugs.openjdk.java.net/browse/JDK-8253208 to move CDS method to CDS.java
Right, will change that to the suggestion.
@yminqi this pull request can not be integrated into
git checkout jdk-8247536 git fetch https://git.openjdk.java.net/jdk master git merge FETCH_HEAD # resolve conflicts and follow the instructions given by git merge git commit -m "Merge master" git push
…ration. There is a trailing LF (Line Feed) so trim white spaces from both front and end of the line or it will fail method type validation.
…ccording to the changes. The invoke name verififcation is not implemented since not all the holder class are processed, not all the functions of processed holder classes are added. For holder class with DirectMethodHandle in its name, only the name in the DMH_METHOD_TYPE_MAP keyset is added, ithe line with other names just gets skipped silently. This makes the verification on invoke names difficul, a name not in the keyset should not fail the test. Also add a boolean to cdsGenerateHolderClasses to indicate call path.
…p to CDS as generateLambdaFormHolderClasses. Added input verification function in CDS before class generation. Added more test scenarios. Removed trailing unused ending words for output of lambda form trace line in case of DumpLoadedClassList.
…sed variables after last change.
…he existing function to log lambda form invokers. Changed isDumpLoadedClassList to a reasonable name isDumpingClassList as read only in CDS.
@yminqi This change now passes all automated pre-integration checks.
After integration, the commit message for the final commit will be:
At the time when this comment was updated there had been 61 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.
…access it. Changed function validateInputLines to isValidInputLines and return a boolean to indicate its valid. Added more comments for review concern.
…ong inputs. Fixed missed archive_mirror issue which could lead crash for archived heap iteration. After call generateLambdaFormHolderClasses, should check exception first. Added more comments why print out exception message and stacktrace in CDS.
@yminqi Since your change was applied there have been 61 commits pushed to the
Your commit was automatically rebased without conflicts.
Pushed as commit e4469d2.