OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 1108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1119 | 1119 |
1120 void AllocationSite::AllocationSitePrint(FILE* out) { | 1120 void AllocationSite::AllocationSitePrint(FILE* out) { |
1121 HeapObject::PrintHeader(out, "AllocationSite"); | 1121 HeapObject::PrintHeader(out, "AllocationSite"); |
1122 PrintF(out, " - weak_next: "); | 1122 PrintF(out, " - weak_next: "); |
1123 weak_next()->ShortPrint(out); | 1123 weak_next()->ShortPrint(out); |
1124 PrintF(out, "\n - dependent code: "); | 1124 PrintF(out, "\n - dependent code: "); |
1125 dependent_code()->ShortPrint(out); | 1125 dependent_code()->ShortPrint(out); |
1126 PrintF(out, "\n - nested site: "); | 1126 PrintF(out, "\n - nested site: "); |
1127 nested_site()->ShortPrint(out); | 1127 nested_site()->ShortPrint(out); |
1128 PrintF(out, "\n - transition_info: "); | 1128 PrintF(out, "\n - transition_info: "); |
1129 if (transition_info()->IsCell()) { | 1129 if (transition_info()->IsSmi()) { |
1130 Cell* cell = Cell::cast(transition_info()); | 1130 ElementsKind kind = GetElementsKind(); |
1131 Object* cell_contents = cell->value(); | 1131 PrintF(out, "Array allocation with ElementsKind "); |
1132 if (cell_contents->IsSmi()) { | 1132 PrintElementsKind(out, kind); |
1133 ElementsKind kind = static_cast<ElementsKind>( | 1133 PrintF(out, "\n"); |
1134 Smi::cast(cell_contents)->value()); | 1134 return; |
1135 PrintF(out, "Array allocation with ElementsKind "); | |
1136 PrintElementsKind(out, kind); | |
1137 PrintF(out, "\n"); | |
1138 return; | |
1139 } | |
1140 } else if (transition_info()->IsJSArray()) { | 1135 } else if (transition_info()->IsJSArray()) { |
1141 PrintF(out, "Array literal "); | 1136 PrintF(out, "Array literal "); |
1142 transition_info()->ShortPrint(out); | 1137 transition_info()->ShortPrint(out); |
1143 PrintF(out, "\n"); | 1138 PrintF(out, "\n"); |
1144 return; | 1139 return; |
1145 } | 1140 } |
1146 | 1141 |
1147 PrintF(out, "unknown transition_info"); | 1142 PrintF(out, "unknown transition_info"); |
1148 transition_info()->ShortPrint(out); | 1143 transition_info()->ShortPrint(out); |
1149 PrintF(out, "\n"); | 1144 PrintF(out, "\n"); |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1257 } | 1252 } |
1258 } | 1253 } |
1259 PrintF(out, "\n"); | 1254 PrintF(out, "\n"); |
1260 } | 1255 } |
1261 | 1256 |
1262 | 1257 |
1263 #endif // OBJECT_PRINT | 1258 #endif // OBJECT_PRINT |
1264 | 1259 |
1265 | 1260 |
1266 } } // namespace v8::internal | 1261 } } // namespace v8::internal |
OLD | NEW |