Change root visitor to use Object**.
Simplifies code and improves the performance of root visiting since
we usually don't need to check to see if the object moved.
Change-Id: Iba998f5a15ae1fa1b53ca5226dd2168a411196cf
diff --git a/runtime/mirror/throwable.cc b/runtime/mirror/throwable.cc
index fef7d36..4c53993 100644
--- a/runtime/mirror/throwable.cc
+++ b/runtime/mirror/throwable.cc
@@ -99,8 +99,7 @@
void Throwable::VisitRoots(RootCallback* callback, void* arg) {
if (java_lang_Throwable_ != nullptr) {
- java_lang_Throwable_ = down_cast<Class*>(callback(java_lang_Throwable_, arg, 0,
- kRootStickyClass));
+ callback(reinterpret_cast<mirror::Object**>(&java_lang_Throwable_), arg, 0, kRootStickyClass);
}
}