ahat: support java.lang.ref.Finalizer
Because some implementations use that in contrast to ART's
java.lang.ref.FinalizerReference to track finalizers.
Bug: 111867529
Test: m ahat-test, with new test added.
Change-Id: Id9ae4e32f0e6c852fabbb73c790dbd7d9f28c51f
diff --git a/tools/ahat/src/ri-test-dump/Main.java b/tools/ahat/src/ri-test-dump/Main.java
index 0f5f480..9df53f4 100644
--- a/tools/ahat/src/ri-test-dump/Main.java
+++ b/tools/ahat/src/ri-test-dump/Main.java
@@ -23,6 +23,7 @@
* Program used to create an RI heap dump for test purposes.
*/
public class Main {
+ public static DumpedStuff stuff;
public static void main(String[] args) throws IOException {
if (args.length < 1) {
@@ -31,6 +32,8 @@
}
String file = args[0];
+ stuff = new DumpedStuff();
+
// Take a heap dump of this process.
MBeanServer server = ManagementFactory.getPlatformMBeanServer();
HotSpotDiagnosticMXBean bean = ManagementFactory.newPlatformMXBeanProxy(server,