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

Shenandoah wastes memory when running with very large page sizes

    XMLWordPrintable

Details

    • gc

    Description

      Shenandoah allocates almost all support regions with the largest possible page size; in case of 1G pages, this results in:

      ```
      thomas@starfish$ java -Xmx4600m -Xlog:pagesize -XX:+UseShenandoahGC -XX:+UseLargePages
      ...
      [0.006s][info][pagesize] Heap: req_size=5G base=0x00000006c0000000 page_size=1G alignment=1G size=5G
      [0.006s][info][pagesize] Mark Bitmap: req_size=160M base=0x00007fc4c0000000 page_size=1G alignment=1G size=1G
      [0.011s][info][pagesize] Aux Bitmap: req_size=160M base=0x00007fc4c0000000 page_size=1G alignment=1G size=1G
      [0.011s][info][pagesize] Region Storage: req_size=320K base=0x00007fc3c0000000 page_size=1G alignment=1G size=1G
      [0.011s][info][pagesize] Collection Set: req_size=16K base=0x0000000000010000 page_size=4K alignment=4K size=16K
      ```

      each mark bitmap and the region storage live in separate 1G pages, wasting between 1.xx and 3.xx GB depending on whether the Aux bitmap is committed and the verification bitmap is used.

      Note that the heap size is also rounded up, but at least we use that additional memory.

      Attachments

        Issue Links

          Activity

            People

              stuefe Thomas Stuefe
              stuefe Thomas Stuefe
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated: