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

The upper bound of GCCardSizeInBytes should be limited to 512 for 32-bit platforms

XMLWordPrintable

    • gc
    • behavioral
    • minimal
    • This is a change to a command line option introduced in JDK 18. Since there has been no official release, there can be no compatibility risk.
    • add/remove/modify command line option
    • Implementation

      Summary

      The upper bound for the GCCardSizeInBytes option must be 512 bytes for 32 bit platforms.

      Problem

      In JDK-8275142 the new option GCCardSizeInBytes as been introduced with upper bounds of 1024 bytes for all platforms. This value does not work for 32 bit platforms due to implementation limitations.

      Solution

      Reduce the upper bound of GCCardSizeInBytes to 512 bytes for 32 bit platforms.

      Specification

      diff --git a/src/hotspot/share/gc/shared/gc_globals.hpp b/src/hotspot/share/gc/shared/gc_globals.hpp
      index b57be5abf62..684357297d8 100644
      --- a/src/hotspot/share/gc/shared/gc_globals.hpp
      +++ b/src/hotspot/share/gc/shared/gc_globals.hpp
      @@ -696,7 +696,7 @@
                                                                                   \
         product(uint, GCCardSizeInBytes, 512,                                     \
                 "Card table entry size (in bytes) for card based collectors")     \
      -          range(128, 1024)                                                  \
      +          range(128, NOT_LP64(512) LP64_ONLY(1024))                         \
                 constraint(GCCardSizeInBytesConstraintFunc,AtParse)
         // end of GC_FLAGS

            jiefu Jie Fu
            jiefu Jie Fu
            Albert Yang, Thomas Schatzl
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: