OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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/snapshot/serializer.h" | 5 #include "src/snapshot/serializer.h" |
6 | 6 |
7 #include "src/macro-assembler.h" | 7 #include "src/macro-assembler.h" |
8 #include "src/snapshot/natives.h" | 8 #include "src/snapshot/natives.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
309 } | 309 } |
310 | 310 |
311 void Serializer::ObjectSerializer::SerializePrologue(AllocationSpace space, | 311 void Serializer::ObjectSerializer::SerializePrologue(AllocationSpace space, |
312 int size, Map* map) { | 312 int size, Map* map) { |
313 if (serializer_->code_address_map_) { | 313 if (serializer_->code_address_map_) { |
314 const char* code_name = | 314 const char* code_name = |
315 serializer_->code_address_map_->Lookup(object_->address()); | 315 serializer_->code_address_map_->Lookup(object_->address()); |
316 LOG(serializer_->isolate_, | 316 LOG(serializer_->isolate_, |
317 CodeNameEvent(object_->address(), sink_->Position(), code_name)); | 317 CodeNameEvent(object_->address(), sink_->Position(), code_name)); |
318 LOG(serializer_->isolate_, | 318 LOG(serializer_->isolate_, |
319 SnapshotPositionEvent(object_->address(), sink_->Position())); | 319 SnapshotPositionEvent(object_, sink_->Position())); |
320 } | 320 } |
321 | 321 |
322 BackReference back_reference; | 322 BackReference back_reference; |
323 if (space == LO_SPACE) { | 323 if (space == LO_SPACE) { |
324 sink_->Put(kNewObject + reference_representation_ + space, | 324 sink_->Put(kNewObject + reference_representation_ + space, |
325 "NewLargeObject"); | 325 "NewLargeObject"); |
326 sink_->PutInt(size >> kObjectAlignmentBits, "ObjectSizeInWords"); | 326 sink_->PutInt(size >> kObjectAlignmentBits, "ObjectSizeInWords"); |
327 if (object_->IsCode()) { | 327 if (object_->IsCode()) { |
328 sink_->Put(EXECUTABLE, "executable large object"); | 328 sink_->Put(EXECUTABLE, "executable large object"); |
329 } else { | 329 } else { |
(...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
760 if (to_skip != 0 && return_skip == kIgnoringReturn) { | 760 if (to_skip != 0 && return_skip == kIgnoringReturn) { |
761 sink_->Put(kSkip, "Skip"); | 761 sink_->Put(kSkip, "Skip"); |
762 sink_->PutInt(to_skip, "SkipDistance"); | 762 sink_->PutInt(to_skip, "SkipDistance"); |
763 to_skip = 0; | 763 to_skip = 0; |
764 } | 764 } |
765 return to_skip; | 765 return to_skip; |
766 } | 766 } |
767 | 767 |
768 } // namespace internal | 768 } // namespace internal |
769 } // namespace v8 | 769 } // namespace v8 |
OLD | NEW |