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/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
8 #include "src/api.h" | 8 #include "src/api.h" |
9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
10 #include "src/base/once.h" | 10 #include "src/base/once.h" |
(...skipping 5443 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5454 } | 5454 } |
5455 | 5455 |
5456 | 5456 |
5457 bool Heap::CreateHeapObjects() { | 5457 bool Heap::CreateHeapObjects() { |
5458 // Create initial maps. | 5458 // Create initial maps. |
5459 if (!CreateInitialMaps()) return false; | 5459 if (!CreateInitialMaps()) return false; |
5460 CreateApiObjects(); | 5460 CreateApiObjects(); |
5461 | 5461 |
5462 // Create initial objects | 5462 // Create initial objects |
5463 CreateInitialObjects(); | 5463 CreateInitialObjects(); |
5464 CHECK_EQ(0, gc_count_); | 5464 CHECK_EQ(0u, gc_count_); |
5465 | 5465 |
5466 set_native_contexts_list(undefined_value()); | 5466 set_native_contexts_list(undefined_value()); |
5467 set_array_buffers_list(undefined_value()); | 5467 set_array_buffers_list(undefined_value()); |
5468 set_allocation_sites_list(undefined_value()); | 5468 set_allocation_sites_list(undefined_value()); |
5469 weak_object_to_code_table_ = undefined_value(); | 5469 weak_object_to_code_table_ = undefined_value(); |
5470 return true; | 5470 return true; |
5471 } | 5471 } |
5472 | 5472 |
5473 | 5473 |
5474 void Heap::SetStackLimits() { | 5474 void Heap::SetStackLimits() { |
(...skipping 978 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6453 static_cast<int>(object_sizes_last_time_[index])); | 6453 static_cast<int>(object_sizes_last_time_[index])); |
6454 CODE_AGE_LIST_COMPLETE(ADJUST_LAST_TIME_OBJECT_COUNT) | 6454 CODE_AGE_LIST_COMPLETE(ADJUST_LAST_TIME_OBJECT_COUNT) |
6455 #undef ADJUST_LAST_TIME_OBJECT_COUNT | 6455 #undef ADJUST_LAST_TIME_OBJECT_COUNT |
6456 | 6456 |
6457 MemCopy(object_counts_last_time_, object_counts_, sizeof(object_counts_)); | 6457 MemCopy(object_counts_last_time_, object_counts_, sizeof(object_counts_)); |
6458 MemCopy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_)); | 6458 MemCopy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_)); |
6459 ClearObjectStats(); | 6459 ClearObjectStats(); |
6460 } | 6460 } |
6461 } | 6461 } |
6462 } // namespace v8::internal | 6462 } // namespace v8::internal |
OLD | NEW |