| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/objects.h" | 5 #include "src/objects.h" |
| 6 | 6 |
| 7 #include "src/disasm.h" | 7 #include "src/disasm.h" |
| 8 #include "src/disassembler.h" | 8 #include "src/disassembler.h" |
| 9 #include "src/interpreter/bytecodes.h" | 9 #include "src/interpreter/bytecodes.h" |
| 10 #include "src/objects-inl.h" | 10 #include "src/objects-inl.h" |
| (...skipping 579 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 590 | 590 |
| 591 | 591 |
| 592 void TypeFeedbackVector::TypeFeedbackVectorPrint(std::ostream& os) { // NOLINT | 592 void TypeFeedbackVector::TypeFeedbackVectorPrint(std::ostream& os) { // NOLINT |
| 593 HeapObject::PrintHeader(os, "TypeFeedbackVector"); | 593 HeapObject::PrintHeader(os, "TypeFeedbackVector"); |
| 594 os << " - length: " << length(); | 594 os << " - length: " << length(); |
| 595 if (length() == 0) { | 595 if (length() == 0) { |
| 596 os << " (empty)\n"; | 596 os << " (empty)\n"; |
| 597 return; | 597 return; |
| 598 } | 598 } |
| 599 | 599 |
| 600 os << "\n - ics with type info: " << ic_with_type_info_count(); | |
| 601 os << "\n - generic ics: " << ic_generic_count(); | |
| 602 | |
| 603 TypeFeedbackMetadataIterator iter(metadata()); | 600 TypeFeedbackMetadataIterator iter(metadata()); |
| 604 while (iter.HasNext()) { | 601 while (iter.HasNext()) { |
| 605 FeedbackVectorSlot slot = iter.Next(); | 602 FeedbackVectorSlot slot = iter.Next(); |
| 606 FeedbackVectorSlotKind kind = iter.kind(); | 603 FeedbackVectorSlotKind kind = iter.kind(); |
| 607 | 604 |
| 608 os << "\n Slot " << slot << " " << kind << " "; | 605 os << "\n Slot " << slot << " " << kind << " "; |
| 609 switch (kind) { | 606 switch (kind) { |
| 610 case FeedbackVectorSlotKind::LOAD_IC: { | 607 case FeedbackVectorSlotKind::LOAD_IC: { |
| 611 LoadICNexus nexus(this, slot); | 608 LoadICNexus nexus(this, slot); |
| 612 os << Code::ICState2String(nexus.StateFromFeedback()); | 609 os << Code::ICState2String(nexus.StateFromFeedback()); |
| (...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1313 void JSObject::PrintTransitions(std::ostream& os) { // NOLINT | 1310 void JSObject::PrintTransitions(std::ostream& os) { // NOLINT |
| 1314 Object* transitions = map()->raw_transitions(); | 1311 Object* transitions = map()->raw_transitions(); |
| 1315 int num_transitions = TransitionArray::NumberOfTransitions(transitions); | 1312 int num_transitions = TransitionArray::NumberOfTransitions(transitions); |
| 1316 if (num_transitions == 0) return; | 1313 if (num_transitions == 0) return; |
| 1317 os << "\n - transitions"; | 1314 os << "\n - transitions"; |
| 1318 TransitionArray::PrintTransitions(os, transitions, false); | 1315 TransitionArray::PrintTransitions(os, transitions, false); |
| 1319 } | 1316 } |
| 1320 #endif // defined(DEBUG) || defined(OBJECT_PRINT) | 1317 #endif // defined(DEBUG) || defined(OBJECT_PRINT) |
| 1321 } // namespace internal | 1318 } // namespace internal |
| 1322 } // namespace v8 | 1319 } // namespace v8 |
| OLD | NEW |