Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8306720

Whether hotspot8 should set a larger default heap size

XMLWordPrintable

    • x86_64
    • linux

      ADDITIONAL SYSTEM INFORMATION :
      22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Mar 17 21:16:15 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

      openjdk version "1.8.0_362"
      OpenJDK Runtime Environment (Temurin)(build 1.8.0_362-b09)
      OpenJDK 64-Bit Server VM (Temurin)(build 25.362-b09, mixed mode)

      openjdk version "11.0.18" 2023-01-17
      OpenJDK Runtime Environment Temurin-11.0.18+10 (build 11.0.18+10)
      OpenJDK 64-Bit Server VM Temurin-11.0.18+10 (build 11.0.18+10, mixed mode)

      openjdk version "17.0.6" 2023-01-17
      OpenJDK Runtime Environment Temurin-17.0.6+10 (build 17.0.6+10)
      OpenJDK 64-Bit Server VM Temurin-17.0.6+10 (build 17.0.6+10, mixed mode, sharing)


      A DESCRIPTION OF THE PROBLEM :
      During our implementation, we found that hotspot8 could not create an integer array of size 536870913 and reported an OOM. However, when we test with openj9-8, openj9-11, openj9-17, hotspot11, hotspot17, we do not report OOM. Does this mean that hotspot8's default heap size is too small?

       



      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      nothing
      ACTUAL -
      Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
      at testcase2.main(testcase2.java:8)

      ---------- BEGIN SOURCE ----------
      public class testcase2 {
          public static int[] dst2;

          public testcase2() {
          }

          public static void main(String[] var0) {
              dst2 = new int[536870913];
          }
      }
      ---------- END SOURCE ----------

      FREQUENCY : always


            Unassigned Unassigned
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: