wilx commented on PR #9486: URL: https://github.com/apache/netbeans/pull/9486#issuecomment-4892963693
I dug further into this, and this PR is only a stopgap. It prevents the crash, but it does not solve the underlying modeling issue. `ROOT_STICKY_CLASS` roots point at class objects / `CLASS_DUMP` IDs, not ordinary `INSTANCE_DUMP` records. The current lookup path tries to resolve every GC root through the normal instance index, so these roots can resolve to `null`. This patch avoids dereferencing that `null`, but it also means those sticky-class roots are not represented in the `Instance -> GCRoot` lookup. A fuller fix would probably need to resolve sticky-class roots through the class-dump model, e.g. to a `ClassDumpInstance`, and make sure nearest-GC-root / retained-size traversal can use those class objects as roots. Without that, static-field reachability rooted only through sticky classes may still be underrepresented, even though the heap dump itself is parsed. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected] For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
