Reference type propagation
- propagate reference types between instructions
- remove checked casts when possible
- add StackHandleScopeCollection to manage an arbitrary number of stack
handles (see comments)
Change-Id: I31200067c5e7375a5ea8e2f873c4374ebdb5ee60
diff --git a/compiler/optimizing/nodes.cc b/compiler/optimizing/nodes.cc
index 4a574b0..7a75d26 100644
--- a/compiler/optimizing/nodes.cc
+++ b/compiler/optimizing/nodes.cc
@@ -18,6 +18,7 @@
#include "ssa_builder.h"
#include "utils/growable_array.h"
+#include "scoped_thread_state_change.h"
namespace art {
@@ -999,4 +1000,14 @@
invoke->GetBlock()->RemoveInstruction(invoke);
}
+std::ostream& operator<<(std::ostream& os, const ReferenceTypeInfo& rhs) {
+ ScopedObjectAccess soa(Thread::Current());
+ os << "["
+ << " is_top=" << rhs.IsTop()
+ << " type=" << (rhs.IsTop() ? "?" : PrettyClass(rhs.GetTypeHandle().Get()))
+ << " is_exact=" << rhs.IsExact()
+ << " ]";
+ return os;
+}
+
} // namespace art