[jdk21u] RFR: 8240567: MethodTooLargeException thrown while creating a jlink image

Paul Hohensee phh at openjdk.org
Wed Aug 16 20:53:52 UTC 2023


On Wed, 16 Aug 2023 18:19:12 GMT, Mandy Chung <mchung at openjdk.org> wrote:

> Manually resolved the merge conflict due to JDK-8310848 which is not in jdk21u.   Trivial 1-line change:
> 
> 
> diff --git a/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/SystemModulesPlugin.java b/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/SystemModulesPlugin.java
> index 1ec5f750f4c..563371b05a1 100644
> --- a/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/SystemModulesPlugin.java
> +++ b/src/jdk.jlink/share/classes/jdk/tools/jlink/internal/plugins/SystemModulesPlugin.java
> @@ -685,7 +685,7 @@ public final class SystemModulesPlugin extends AbstractPlugin {
>              if (moduleInfos.size() <= moduleDescriptorsPerMethod) {
>                  clb.withMethodBody(
>                          "moduleDescriptors",
> -                        MTD_ModuleDescriptorArray,
> +                        MethodTypeDesc.of(CD_MODULE_DESCRIPTOR.arrayType()),
>                          ACC_PUBLIC,
>                          cob -> {
>                              cob.constantInstruction(moduleInfos.size())

Are the definitions of MTD_StringArray and MTD_SystemModules in SystemModulesPlugin.java needed? They're not in the original commit and aren't referenced by the patch.

-------------

PR Review: https://git.openjdk.org/jdk21u/pull/65#pullrequestreview-1581391924


More information about the jdk-updates-dev mailing list