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

C1/C2 don't handle allocation failure properly during initialization (RuntimeStub::new_runtime_stub fatal crash)

    XMLWordPrintable

Details

    • b14
    • x86_64
    • linux

    Description

      compiler/startup/StartupOutput.java intermittently Internal Error (codeBlob.cpp:429) Initial size of CodeCache is too small

      test command:
      export test=test/hotspot/jtreg/compiler/startup/StartupOutput.java
      function runJtreg() { jtreg -ea -esa -timeoutFactor:4 -v:fail,error,time,nopass -nr -w $dir/index-$1 $test &> $dir/$1.log ; if [[ 0 -ne $? ]] ; then echo -n "$1 " ; else rm -rf $dir/index-$1 $dir/$1.log ; fi ; } ; export -f runJtreg ; export dir="tmp-jtreg-"`basename ${test##* } .java | sed "s|#|_|"` ; rm -rf $dir ; mkdir -p $dir ; time seq 1000 | xargs -i -n 1 -P `nproc` bash -c "runJtreg {}" ; echo total fail number: `ls $dir/*.log 2> /dev/null | wc | awk '{print $1}'`

      result:
      STDERR:
       stdout: [[0.043s][warning][codecache] CodeCache is full. Compiler has been disabled.
      [0.043s][warning][codecache] Try increasing the code cache size using -XX:ReservedCodeCacheSize=
      CodeCache: size=1200Kb used=1199Kb max_used=1199Kb free=0Kb
       bounds [0x00007f2ca0687000, 0x00007f2ca07b3000, 0x00007f2ca07b3000]
       total_blobs=285, nmethods=0, adapters=199, full_count=1
      Compilation: disabled (not enough contiguous free space left), stopped_count=1, restarted_count=0
      #
      # A fatal error has been detected by the Java Runtime Environment:
      #
      # Internal Error (codeBlob.cpp:429), pid=155190, tid=155378
      # fatal error: Initial size of CodeCache is too small
      #
      # JRE version: OpenJDK Runtime Environment (23.0) (build 23)
      # Java VM: OpenJDK 64-Bit Server VM (23, mixed mode, sharing, tiered, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
      # Problematic frame:
      # V [libjvm.so+0x6495cc] RuntimeStub::new_runtime_stub(char const*, CodeBuffer*, int, int, OopMapSet*, bool, bool)+0x16c
      #
      # Core dump will be written. Default location: /var/tmp/tone/run/jtreg/jt-work/index-14/compiler/startup/StartupOutput/core.155190
      #
      # An error report file with more information is saved as:
      # /var/tmp/tone/run/jtreg/jt-work/index-14/compiler/startup/StartupOutput/hs_err_pid155190.log

      [error occurred during error reporting (), id 0xb, SIGSEGV (0xb) at pc=0x00007f2ca105c25a]
      #
      # If you would like to submit a bug report, please visit:
      # mailto:yansendao.ysd@alibaba-inc.com
      #
      ];
       stderr: [OpenJDK 64-Bit Server VM warning: CodeCache is full. Compiler has been disabled.
      OpenJDK 64-Bit Server VM warning: Try increasing the code cache size using -XX:ReservedCodeCacheSize=
      ]
       exitValue = 134


      Recurrence probability: 40/1000


      cpu and enviroment infomation:
      # uname -a ; cat /etc/os-release ; free -h ; lscpu | head -n 25 ; java -version ; java -Xinternalversion
      Linux iZbp15rwnojzp4ihzwephwZ 5.10.134-16.1.al8.x86_64 #1 SMP Thu Dec 7 14:11:24 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
      NAME="Alibaba Cloud Linux"
      VERSION="3 (Soaring Falcon)"
      ID="alinux"
      ID_LIKE="rhel fedora centos anolis"
      VERSION_ID="3"
      UPDATE_ID="9"
      PLATFORM_ID="platform:al8"
      PRETTY_NAME="Alibaba Cloud Linux 3 (Soaring Falcon)"
      ANSI_COLOR="0;31"
      HOME_URL="https://www.aliyun.com/"

                    total used free shared buff/cache available
      Mem: 60Gi 806Mi 3.2Gi 114Mi 56Gi 58Gi
      Swap: 0B 0B 0B
      Architecture: x86_64
      CPU op-mode(s): 32-bit, 64-bit
      Byte Order: Little Endian
      CPU(s): 32
      On-line CPU(s) list: 0-31
      Thread(s) per core: 2
      Core(s) per socket: 16
      Socket(s): 1
      NUMA node(s): 1
      Vendor ID: GenuineIntel
      BIOS Vendor ID: Alibaba Cloud
      CPU family: 6
      Model: 106
      Model name: Intel(R) Xeon(R) Platinum 8369B CPU @ 2.70GHz
      BIOS Model name: pc-i440fx-2.1
      Stepping: 6
      CPU MHz: 3518.694
      BogoMIPS: 5399.99
      Hypervisor vendor: KVM
      Virtualization type: full
      L1d cache: 48K
      L1i cache: 32K
      L2 cache: 1280K
      L3 cache: 49152K
      NUMA node0 CPU(s): 0-31
      openjdk version "23" 2024-09-17
      OpenJDK Runtime Environment (build 23)
      OpenJDK 64-Bit Server VM (build 23, mixed mode, sharing)
      OpenJDK 64-Bit Server VM (23) for linux-amd64 JRE (23), built on 2024-02-24T04:59:15Z by "root" with gcc 9.3.1 20200408 (Red Hat 9.3.1-2)

      Attachments

        1. 14.log
          14 kB
        2. core.155190.tar.xz
          18.43 MB
        3. hs_err_pid155190.log
          69 kB
        4. StartupOutput.jtr
          14 kB
        5. vmprops.log
          0.5 kB
        6. which-container-stdout--2024-02-24T05-04-59-605097412Z.log
          0.0 kB

        Issue Links

          Activity

            People

              dfenacci Damon Fenacci
              syan Sendao Yan
              Votes:
              0 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: