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

[JVMCI] missing barriers in CompilerToVM.readFieldValue for Reference.referent

    XMLWordPrintable

Details

    • b19
    • generic

    Description

      JVMCI provides the ability to reflectively read any field in a Java object. During JIT compilation this is only used to read final fields but native image uses it for heap introspection. In that case it's possible to use it to read Reference.referent but the JVMCI code is using obj_field_acquire which doesn't perform any of the GC barrier work. Native image is always run with -XX:+UseParallelGC for performance but when running with G1 this code can read a weak reference that is going to be released.

      Attachments

        Issue Links

          Activity

            People

              never Tom Rodriguez
              never Tom Rodriguez
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: