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

Capture underlying type for unsafe/unaligned pointers in ClassFileParser

    XMLWordPrintable

    Details

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

      Description

      As part of JDK-8180032 I fixed a problem where ClassFileParser passed around potentially unaligned pointers to various class file data structures, and in some cases dereferenced those unaligned pointers which is not valid in C++. As part of the fix I chose to switch from using typed pointers (like u2*) in favor of void*, to signal that the pointer is not (necessarily) possible to dereference directly. However, by switching to void* the information about the underlying type (u2) is lost, which is unfortunate. The information about the type should be maintained in some way.

        Attachments

          Activity

            People

            Assignee:
            mikael Mikael Vidstedt
            Reporter:
            mikael Mikael Vidstedt
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: