Add root types and thread id to root visiting.
Enables us to pass the root type and thread id to hprof.
Bug: 12680863
Change-Id: I6a0f1f9e3aa8f9b4033d695818ae7ca3460d67cb
diff --git a/runtime/indirect_reference_table.cc b/runtime/indirect_reference_table.cc
index 8194a0d..4a02d74 100644
--- a/runtime/indirect_reference_table.cc
+++ b/runtime/indirect_reference_table.cc
@@ -309,9 +309,10 @@
return true;
}
-void IndirectReferenceTable::VisitRoots(RootVisitor* visitor, void* arg) {
+void IndirectReferenceTable::VisitRoots(RootCallback* callback, void* arg, uint32_t tid,
+ RootType root_type) {
for (auto ref : *this) {
- *ref = visitor(const_cast<mirror::Object*>(*ref), arg);
+ *ref = callback(const_cast<mirror::Object*>(*ref), arg, tid, root_type);
DCHECK(*ref != nullptr);
}
}