diff options
Diffstat (limited to 'compiler/optimizing/graph_visualizer.cc')
-rw-r--r-- | compiler/optimizing/graph_visualizer.cc | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/compiler/optimizing/graph_visualizer.cc b/compiler/optimizing/graph_visualizer.cc index 9e0a5b89e9..ef461d9ac5 100644 --- a/compiler/optimizing/graph_visualizer.cc +++ b/compiler/optimizing/graph_visualizer.cc @@ -68,7 +68,7 @@ class HGraphVisualizerPrinter : public HGraphVisitor { void PrintTime(const char* name) { AddIndent(); - output_ << name << " " << time(NULL) << std::endl; + output_ << name << " " << time(nullptr) << std::endl; } void PrintInt(const char* name, int value) { @@ -142,6 +142,10 @@ class HGraphVisualizerPrinter : public HGraphVisitor { codegen_.DumpFloatingPointRegister(output_, location.low()); output_ << " and "; codegen_.DumpFloatingPointRegister(output_, location.high()); + } else if (location.IsRegisterPair()) { + codegen_.DumpCoreRegister(output_, location.low()); + output_ << " and "; + codegen_.DumpCoreRegister(output_, location.high()); } else { DCHECK(location.IsDoubleStackSlot()); output_ << "2x" << location.GetStackIndex() << "(sp)"; @@ -219,10 +223,16 @@ class HGraphVisualizerPrinter : public HGraphVisitor { const char* kEndInstructionMarker = "<|@"; for (HInstructionIterator it(list); !it.Done(); it.Advance()) { HInstruction* instruction = it.Current(); - AddIndent(); int bci = 0; - output_ << bci << " " << instruction->NumberOfUses() - << " " << GetTypeId(instruction->GetType()) << instruction->GetId() << " "; + size_t num_uses = 0; + for (HUseIterator<HInstruction*> use_it(instruction->GetUses()); + !use_it.Done(); + use_it.Advance()) { + ++num_uses; + } + AddIndent(); + output_ << bci << " " << num_uses << " " + << GetTypeId(instruction->GetType()) << instruction->GetId() << " "; PrintInstruction(instruction); output_ << kEndInstructionMarker << std::endl; } |