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

max_heap_for_compressed_oops() declared with size_t, but defined with uintx

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P5
    • Resolution: Fixed
    • Affects Version/s: 9
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
      gc
    • Resolved In Build:
      b17

      Backports

        Description

        From http://mail.openjdk.java.net/pipermail/hotspot-dev/2014-May/014020.html

        I've created a patch [1] to fix usage of uintx where size_t type is
        expected in hotspot/src/share/vm/runtime/arguments.cpp

        The Arguments::max_heap_for_compressed_oops() method is declared in
        arguments.hpp as
        size_t max_heap_for_compressed_oops()
        but later defined in arguments.cpp as
        uintx max_heap_for_compressed_oops()

        For most platforms the uintx and size_t types are effectively the
        same, so the interchange is uncaught, but on s390 (32-bit) the size_t is
        "unsigned long" which makes it incompatible with "unsigned int".

          Activity

          Hide
          tschatzl Thomas Schatzl added a comment -
          Assigning to GC because it seems to be related to heap sizing code.
          Show
          tschatzl Thomas Schatzl added a comment - Assigning to GC because it seems to be related to heap sizing code.
          Hide
          tschatzl Thomas Schatzl added a comment -
          Patch contributed by Dan Horák from RedHat
          Show
          tschatzl Thomas Schatzl added a comment - Patch contributed by Dan Horák from RedHat
          Hide
          pliden Per Liden added a comment -
          This mixing of types should be cleaned up, even if we don't support s390.

          ILW=LLH=P5
          Show
          pliden Per Liden added a comment - This mixing of types should be cleaned up, even if we don't support s390. ILW=LLH=P5
          Hide
          hgupdate HG Updates added a comment -
          URL: http://hg.openjdk.java.net/jdk9/hs-gc/hotspot/rev/68e6defdb086
          User: tschatzl
          Date: 2014-05-26 08:37:53 +0000
          Show
          hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/hs-gc/hotspot/rev/68e6defdb086 User: tschatzl Date: 2014-05-26 08:37:53 +0000
          Hide
          hgupdate HG Updates added a comment -
          URL: http://hg.openjdk.java.net/jdk9/jdk9/hotspot/rev/68e6defdb086
          User: lana
          Date: 2014-06-11 18:25:52 +0000
          Show
          hgupdate HG Updates added a comment - URL: http://hg.openjdk.java.net/jdk9/jdk9/hotspot/rev/68e6defdb086 User: lana Date: 2014-06-11 18:25:52 +0000

            People

            • Assignee:
              tschatzl Thomas Schatzl
              Reporter:
              tschatzl Thomas Schatzl
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: