| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/locations.h" | 5 #include "vm/locations.h" |
| 6 | 6 |
| 7 #include "vm/il_printer.h" | 7 #include "vm/il_printer.h" |
| 8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
| 9 #include "vm/flow_graph_compiler.h" | 9 #include "vm/flow_graph_compiler.h" |
| 10 | 10 |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 default: | 85 default: |
| 86 ASSERT(IsConstant()); | 86 ASSERT(IsConstant()); |
| 87 return "C"; | 87 return "C"; |
| 88 } | 88 } |
| 89 return "?"; | 89 return "?"; |
| 90 } | 90 } |
| 91 | 91 |
| 92 | 92 |
| 93 void Location::PrintTo(BufferFormatter* f) const { | 93 void Location::PrintTo(BufferFormatter* f) const { |
| 94 if (kind() == kStackSlot) { | 94 if (kind() == kStackSlot) { |
| 95 f->Print("S%+d", stack_index()); | 95 f->Print("S%+"Pd"", stack_index()); |
| 96 } else if (kind() == kDoubleStackSlot) { | 96 } else if (kind() == kDoubleStackSlot) { |
| 97 f->Print("DS%+d", stack_index()); | 97 f->Print("DS%+"Pd"", stack_index()); |
| 98 } else { | 98 } else { |
| 99 f->Print("%s", Name()); | 99 f->Print("%s", Name()); |
| 100 } | 100 } |
| 101 } | 101 } |
| 102 | 102 |
| 103 | 103 |
| 104 void Location::Print() const { | 104 void Location::Print() const { |
| 105 if (kind() == kStackSlot) { | 105 if (kind() == kStackSlot) { |
| 106 OS::Print("S%+d", stack_index()); | 106 OS::Print("S%+"Pd"", stack_index()); |
| 107 } else { | 107 } else { |
| 108 OS::Print("%s", Name()); | 108 OS::Print("%s", Name()); |
| 109 } | 109 } |
| 110 } | 110 } |
| 111 | 111 |
| 112 | 112 |
| 113 void LocationSummary::PrintTo(BufferFormatter* f) const { | 113 void LocationSummary::PrintTo(BufferFormatter* f) const { |
| 114 if (input_count() > 0) { | 114 if (input_count() > 0) { |
| 115 f->Print(" ("); | 115 f->Print(" ("); |
| 116 for (intptr_t i = 0; i < input_count(); i++) { | 116 for (intptr_t i = 0; i < input_count(); i++) { |
| (...skipping 14 matching lines...) Expand all Loading... |
| 131 | 131 |
| 132 if (!out().IsInvalid()) { | 132 if (!out().IsInvalid()) { |
| 133 f->Print(" => "); | 133 f->Print(" => "); |
| 134 out().PrintTo(f); | 134 out().PrintTo(f); |
| 135 } | 135 } |
| 136 | 136 |
| 137 if (always_calls()) f->Print(" C"); | 137 if (always_calls()) f->Print(" C"); |
| 138 } | 138 } |
| 139 | 139 |
| 140 } // namespace dart | 140 } // namespace dart |
| OLD | NEW |