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

[ZGC] missing null check in ZNMethod::log_register

XMLWordPrintable

    • gc
    • b19
    • ppc

        We are getting SIGSEGV when running the test "runtime/logging/RedefineClasses.java" with ZGC on PPC64.

        The VM crashes while trying to read (*p)->klass() in "ZNMethod::log_register". ā€˜pā€™ points to an Oops table slot in an nmethod which contains a null Oop.

        This happens on PPC64, because C1 allocates Oop slots for PatchingStubs and initializes them to null. (The actual Oop will get inserted during execution time when the PatchingStub gets executed.)
        "ZNMethod::log_register" needs to be able to deal with null Oops on PPC64 for this reason.

        Note: C1 PatchingStubs are not used on aarch64 and x86_64 uses Oops embedded into the instruction stream instead of the nmethod Oop slots.

              mdoerr Martin Doerr
              mdoerr Martin Doerr
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: