mirror of
https://github.com/openjdk/jdk.git
synced 2026-05-17 17:07:53 +00:00
6892742: Improve root set used by jhat
Reviewed-by: tbell, dcubed
This commit is contained in:
parent
5ef31ba152
commit
f1fd7e28fe
@ -57,7 +57,10 @@ public class JavaStatic {
|
||||
id = ((JavaObjectRef)value).getId();
|
||||
}
|
||||
value = value.dereference(snapshot, field);
|
||||
if (value.isHeapAllocated()) {
|
||||
if (value.isHeapAllocated() &&
|
||||
clazz.getLoader() == snapshot.getNullThing()) {
|
||||
// static fields are only roots if they are in classes
|
||||
// loaded by the root classloader.
|
||||
JavaHeapObject ho = (JavaHeapObject) value;
|
||||
String s = "Static reference from " + clazz.getName()
|
||||
+ "." + field.getName();
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user