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

LOOM: SA needs to add support for scanning StackChunks

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P4
    • tbd
    • 19, repo-loom
    • hotspot

    Description

      SA needs to add support for scanning StackChunks in order for the "reverse pointer" support to work properly and find references to objects that come via a StackChunk (directly or indirectly).

      The heap scanning starts with the roots, and then does recursive scans of each root object. I've been tracking down how it does this recursive scan. It looks like when visiting a non-array type, you end up in the following Oop method:

        public void iterateFields(OopVisitor visitor, boolean doVMFields) {
          super.iterateFields(visitor, doVMFields);
          ((InstanceKlass) getKlass()).iterateNonStaticFields(visitor, this);
        }

      I think if we add InstanceStackChunkKlass::iterateNonStaticFields(), we can have it make the visitor.doOop() call for each oop in the StackChunk, so this might be pretty easy to do. Writing a test will probably be the hardest part.

      Attachments

        Issue Links

          Activity

            People

              cjplummer Chris Plummer
              cjplummer Chris Plummer
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated: