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

ZGC: Improve small heap usage

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 14
    • Fix Version/s: 14
    • Component/s: hotspot
    • Labels:
    • Subcomponent:
      gc
    • Resolved In Build:
      b24

      Description

      When using small heaps (like less than 128M), the heap reserve tends to take up a relatively large portion of the heap. We have quite a lot of tests that explicitly set the heap size to small values (like -Xmx8M, -Xmx16M, etc). Today, these tests fail with OOME when using ZGC. While ZGC isn't really that focused on tiny/small heaps, we still want to make testing of ZGC easy without having to patch these tests to use a larger heap.

      There are at least two things we can do when ZGC is given a small heap:
      1) Dynamically scale the medium ZPage size, and even disable medium pages all together when using tiny heaps.
      2) Stop using per-CPU small pages for allocations, and instead switch to using a single small page.

        Attachments

          Activity

            People

            • Assignee:
              pliden Per Liden
              Reporter:
              pliden Per Liden
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: