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 4598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4609 heap_state.contexts_disposal_rate = | 4609 heap_state.contexts_disposal_rate = |
4610 tracer()->ContextDisposalRateInMilliseconds(); | 4610 tracer()->ContextDisposalRateInMilliseconds(); |
4611 heap_state.size_of_objects = static_cast<size_t>(SizeOfObjects()); | 4611 heap_state.size_of_objects = static_cast<size_t>(SizeOfObjects()); |
4612 heap_state.incremental_marking_stopped = incremental_marking()->IsStopped(); | 4612 heap_state.incremental_marking_stopped = incremental_marking()->IsStopped(); |
4613 // TODO(ulan): Start incremental marking only for large heaps. | 4613 // TODO(ulan): Start incremental marking only for large heaps. |
4614 heap_state.can_start_incremental_marking = | 4614 heap_state.can_start_incremental_marking = |
4615 incremental_marking()->ShouldActivate() && FLAG_incremental_marking && | 4615 incremental_marking()->ShouldActivate() && FLAG_incremental_marking && |
4616 !mark_compact_collector()->sweeping_in_progress(); | 4616 !mark_compact_collector()->sweeping_in_progress(); |
4617 heap_state.sweeping_in_progress = | 4617 heap_state.sweeping_in_progress = |
4618 mark_compact_collector()->sweeping_in_progress(); | 4618 mark_compact_collector()->sweeping_in_progress(); |
| 4619 heap_state.sweeping_completed = |
| 4620 mark_compact_collector()->IsSweepingCompleted(); |
4619 heap_state.mark_compact_speed_in_bytes_per_ms = | 4621 heap_state.mark_compact_speed_in_bytes_per_ms = |
4620 static_cast<size_t>(tracer()->MarkCompactSpeedInBytesPerMillisecond()); | 4622 static_cast<size_t>(tracer()->MarkCompactSpeedInBytesPerMillisecond()); |
4621 heap_state.incremental_marking_speed_in_bytes_per_ms = static_cast<size_t>( | 4623 heap_state.incremental_marking_speed_in_bytes_per_ms = static_cast<size_t>( |
4622 tracer()->IncrementalMarkingSpeedInBytesPerMillisecond()); | 4624 tracer()->IncrementalMarkingSpeedInBytesPerMillisecond()); |
4623 heap_state.final_incremental_mark_compact_speed_in_bytes_per_ms = | 4625 heap_state.final_incremental_mark_compact_speed_in_bytes_per_ms = |
4624 static_cast<size_t>( | 4626 static_cast<size_t>( |
4625 tracer()->FinalIncrementalMarkCompactSpeedInBytesPerMillisecond()); | 4627 tracer()->FinalIncrementalMarkCompactSpeedInBytesPerMillisecond()); |
4626 heap_state.scavenge_speed_in_bytes_per_ms = | 4628 heap_state.scavenge_speed_in_bytes_per_ms = |
4627 static_cast<size_t>(tracer()->ScavengeSpeedInBytesPerMillisecond()); | 4629 static_cast<size_t>(tracer()->ScavengeSpeedInBytesPerMillisecond()); |
4628 heap_state.used_new_space_size = new_space_.Size(); | 4630 heap_state.used_new_space_size = new_space_.Size(); |
(...skipping 1765 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6394 static_cast<int>(object_sizes_last_time_[index])); | 6396 static_cast<int>(object_sizes_last_time_[index])); |
6395 CODE_AGE_LIST_COMPLETE(ADJUST_LAST_TIME_OBJECT_COUNT) | 6397 CODE_AGE_LIST_COMPLETE(ADJUST_LAST_TIME_OBJECT_COUNT) |
6396 #undef ADJUST_LAST_TIME_OBJECT_COUNT | 6398 #undef ADJUST_LAST_TIME_OBJECT_COUNT |
6397 | 6399 |
6398 MemCopy(object_counts_last_time_, object_counts_, sizeof(object_counts_)); | 6400 MemCopy(object_counts_last_time_, object_counts_, sizeof(object_counts_)); |
6399 MemCopy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_)); | 6401 MemCopy(object_sizes_last_time_, object_sizes_, sizeof(object_sizes_)); |
6400 ClearObjectStats(); | 6402 ClearObjectStats(); |
6401 } | 6403 } |
6402 } | 6404 } |
6403 } // namespace v8::internal | 6405 } // namespace v8::internal |
OLD | NEW |