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

Use DAX in ZGC

XMLWordPrintable

    • Icon: CSR CSR
    • Resolution: Withdrawn
    • Icon: P4 P4
    • 15
    • hotspot
    • gc
    • behavioral
    • minimal
    • User might allocate Java heap to slower disk (e.g. HDD), but `-XX:ZAllowHeapOnFileSystem` is experimental option.
    • add/remove/modify command line option
    • JDK

      Summary

      Introduce new option -XX:ZAllowHeapOnFileSystem to allocate heap for ZGC to filesystem.

      Problem

      ZGC supports tmpfs and hugetlbfs as Java heap backing storage. We can allocate Java heap on NV-DIMM by JEP 316, but ZGC does not support it.

      Solution

      Introduce new option -XX:ZAllowHeapOnFileSystem to allocate heap for ZGC to filesystem.

      According to Linux kernel document for DAX, DAX is supported in ext2, ext4, and xfs. Also we need to mount it with -o dax. So we need to support any filesystems for it.

      This option need to be set combination with -XX:AllocateHeapAt.

      Specification

      --- old/src/hotspot/share/gc/z/z_globals.hpp    2020-02-14 17:56:55.619510600 +0900
      +++ new/src/hotspot/share/gc/z/z_globals.hpp    2020-02-14 17:56:54.823184100 +0900
      @@ -58,6 +58,10 @@
                 "Uncommit memory if it has been unused for the specified "        \
                 "amount of time (in seconds)")                                    \
                                                                                   \
      +  experimental(bool, ZAllowHeapOnFileSystem, false,                         \
      +          "Allow to use filesystem as Java heap backing storage "           \
      +          "specified by -XX:AllocateHeapAt")                                \
      +                                                                            \
         diagnostic(uint, ZStatisticsInterval, 10,                                 \
                 "Time between statistics print outs (in seconds)")                \
                 range(1, (uint)-1)                                                \

            ysuenaga Yasumasa Suenaga
            ysuenaga Yasumasa Suenaga
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: