diff options
author | Calin Juravle <calin@google.com> | 2015-07-22 11:20:14 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2015-07-22 11:20:14 +0000 |
commit | e6e38ce021ef5e0d326d76172307c000e0e6fab3 (patch) | |
tree | c7478d676ab6f0c229f154ab06fbce56f7ae507b /compiler/optimizing/graph_visualizer.cc | |
parent | a3073e24e00274d2957771518be5ecfa74591744 (diff) | |
parent | 3fabec7a25d151b26ba7de13615bbead0dd615a6 (diff) |
Merge "Use the object class as top in reference type propagation"
Diffstat (limited to 'compiler/optimizing/graph_visualizer.cc')
-rw-r--r-- | compiler/optimizing/graph_visualizer.cc | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/compiler/optimizing/graph_visualizer.cc b/compiler/optimizing/graph_visualizer.cc index 694b68ce94..d6b5636edc 100644 --- a/compiler/optimizing/graph_visualizer.cc +++ b/compiler/optimizing/graph_visualizer.cc @@ -469,19 +469,14 @@ class HGraphVisualizerPrinter : public HGraphDelegateVisitor { if (instruction->IsLoadClass()) { ReferenceTypeInfo info = instruction->AsLoadClass()->GetLoadedClassRTI(); ScopedObjectAccess soa(Thread::Current()); - if (info.GetTypeHandle().GetReference() != nullptr) { - StartAttributeStream("klass") << PrettyDescriptor(info.GetTypeHandle().Get()); - } else { - StartAttributeStream("klass") << "unresolved"; - } + DCHECK(info.IsValid()) << "Invalid RTI for " << instruction->DebugName(); + StartAttributeStream("klass") << PrettyDescriptor(info.GetTypeHandle().Get()); + StartAttributeStream("exact") << std::boolalpha << info.IsExact() << std::noboolalpha; } else { ReferenceTypeInfo info = instruction->GetReferenceTypeInfo(); - if (info.IsTop()) { - StartAttributeStream("klass") << "java.lang.Object"; - } else { - ScopedObjectAccess soa(Thread::Current()); - StartAttributeStream("klass") << PrettyDescriptor(info.GetTypeHandle().Get()); - } + ScopedObjectAccess soa(Thread::Current()); + DCHECK(info.IsValid()) << "Invalid RTI for " << instruction->DebugName(); + StartAttributeStream("klass") << PrettyDescriptor(info.GetTypeHandle().Get()); StartAttributeStream("exact") << std::boolalpha << info.IsExact() << std::noboolalpha; } } |