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

G1: Use standard idiom for inlined payload in G1MonotonicArena::Segment

XMLWordPrintable

    • gc

      G1SegmentedArraySegment is an object where arbitrarily sized payload data is inlined into the object.

      There is a `_bottom` pointer in the class that points to this payload just right after this pointer.

      Typically in hotspot gc we tend to use some `sometype _data[1]` or so member to point to that (arbitrarily sized) data.
      It would be preferable to do that here as well.

      The segment payload currently provides a default alignment of 8 bytes; this seems correct for all used classes. Also verify that the payload sizes are multiples of 8 bytes so that the alignment requirement for the members is always met.

      Maybe there is some way to programmatically check that?

            lkorinth Leo Korinth
            tschatzl Thomas Schatzl
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: