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

Remove CompressedKlassPointers::is_valid_base()

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Fixed
    • P4
    • 22
    • 22
    • hotspot
    • b26

    Description

      `CompressedKlassPointers::is_valid_base(addr)` exists to abstract away any platform-specific requirements that may limit the use of an address as narrow Klass encoding base.

      The function only ever mattered on aarch64, where we cannot use any arbitrary address as 64-bit immediate for the base.

      It turns out that explaining the point of this function is difficult since it tries to express a very CPU-specific condition in generic terms. This is one of the cases where a generic wrapper is not helpful; we therefore decided to scrap that function.

      It is only used for two things:
      - asserts at runtime; those are unnecessary since we have an assert in macroAssembler_aarch64.cpp that will fire if the base is not correct
      - the only legitimate use case is checking the user input for -XX:SharedBaseAddress at dump time. We can just express the aarch64 requirement directly, which is clearer to understand.

      (this is a preparatory patch for JDK-8320368)

      Attachments

        Issue Links

          Activity

            People

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

              Dates

                Created:
                Updated:
                Resolved: