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

Refactor/cleanup oopDesc::*_klass_addr

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 16
    • Fix Version/s: 16
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b17

      Description

      Right now this one has the comment mentioning CMS:

      Klass** oopDesc::klass_addr(HeapWord* mem) {
        // Only used internally and with CMS and will not work with
        // UseCompressedOops
        assert(!UseCompressedClassPointers, "only supported with uncompressed klass pointers");
        ByteSize offset = byte_offset_of(oopDesc, _metadata._klass);
        return (Klass**) (((char*)mem) + in_bytes(offset));
      }

      But that is not true, it is used on the generic paths.

      Maybe we can clean up related code a little too.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              shade Aleksey Shipilev
              Reporter:
              shade Aleksey Shipilev
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: