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

ZGC: TestAllocateHeapAt.java should not run with UseLargePages

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 24
    • 24
    • hotspot
    • gc
    • b17

      TestAllocateHeapAt.java expects that creating the heap file works in the current director (`.`). But when using persistent hugepages (-XX:+UseLargePages) this would require the filesystem to be a HugeTLBFS.

      I propose that we do not allow running these tests with persistent hugepages.

      The following two tests fail in the JDK24 CI:

      gc/z/TestAllocateHeapAt.java
      gc/x/TestAllocateHeapAt.java

      This is seen with hugepages testing. We see warnings in the output then the VM fails to start:

      ----------System.err:(36/2261)----------
      Java HotSpot(TM) 64-Bit Server VM warning: Failed to reserve and commit memory using large pages. req_addr: 0x0000000399000000 bytes: 18907922432
       stdout: [[0.005s][info][gc,init] Initializing The Z Garbage Collector
      [0.005s][info][gc,init] Version: 24-ea+16-1680 (fastdebug)
      [0.005s][info][gc,init] Using deprecated non-generational mode
      [0.005s][info][gc,init] NUMA Support: Disabled
      [0.005s][info][gc,init] CPUs: 12 total, 12 available
      [0.005s][info][gc,init] Memory: 72098M
      [0.005s][info][gc,init] Large Page Support: Enabled (Explicit)
      [0.005s][info][gc,init] GC Workers: 1 (dynamic)
      [0.005s][info][gc,init] Address Space Type: Contiguous/Unrestricted/Complete
      [0.005s][info][gc,init] Address Space Size: 512M x 3 = 1536M
      [0.005s][info][gc,init] Heap Backing File: ./#506511511
      [0.005s][info][gc,init] Heap Backing Filesystem: other (0x58465342)
      [0.005s][error][gc ] -XX:+UseLargePages (without -XX:+UseTransparentHugePages) can only be enabled when using a hugetlbfs filesystem
      [0.006s][info ][gc,init] Runtime Workers: 1
      [0.006s][info ][gc ] Using The Z Garbage Collector
      ];
       stderr: [Java HotSpot(TM) 64-Bit Server VM warning: Option ZGenerational was deprecated in version 23.0 and will likely be removed in a future release.
      Java HotSpot(TM) 64-Bit Server VM warning: Non-generational ZGC is deprecated.
      Error: Could not create the Java Virtual Machine.
      Error: A fatal exception has occurred. Program will exit.
      ]
       exitValue = 1

            aboldtch Axel Boldt-Christmas
            dholmes David Holmes
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: