| 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 5570 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5581 | 5581 |
| 5582 | 5582 |
| 5583 void Heap::DampenOldGenerationAllocationLimit(intptr_t old_gen_size, | 5583 void Heap::DampenOldGenerationAllocationLimit(intptr_t old_gen_size, |
| 5584 double gc_speed, | 5584 double gc_speed, |
| 5585 double mutator_speed) { | 5585 double mutator_speed) { |
| 5586 double factor = HeapGrowingFactor(gc_speed, mutator_speed); | 5586 double factor = HeapGrowingFactor(gc_speed, mutator_speed); |
| 5587 intptr_t limit = CalculateOldGenerationAllocationLimit(factor, old_gen_size); | 5587 intptr_t limit = CalculateOldGenerationAllocationLimit(factor, old_gen_size); |
| 5588 if (limit < old_generation_allocation_limit_) { | 5588 if (limit < old_generation_allocation_limit_) { |
| 5589 if (FLAG_trace_gc_verbose) { | 5589 if (FLAG_trace_gc_verbose) { |
| 5590 PrintIsolate(isolate_, "Dampen: old size: %" V8_PTR_PREFIX | 5590 PrintIsolate(isolate_, "Dampen: old size: %" V8_PTR_PREFIX |
| 5591 "d KB, old limit: %" V8_PTR_PREFIX "d KB, \n", | 5591 "d KB, old limit: %" V8_PTR_PREFIX |
| 5592 "new limit: %" V8_PTR_PREFIX "d KB (%.1f)\n", | 5592 "d KB, " |
| 5593 "new limit: %" V8_PTR_PREFIX "d KB (%.1f)\n", |
| 5593 old_gen_size / KB, old_generation_allocation_limit_ / KB, | 5594 old_gen_size / KB, old_generation_allocation_limit_ / KB, |
| 5594 limit / KB, factor); | 5595 limit / KB, factor); |
| 5595 } | 5596 } |
| 5596 old_generation_allocation_limit_ = limit; | 5597 old_generation_allocation_limit_ = limit; |
| 5597 } | 5598 } |
| 5598 } | 5599 } |
| 5599 | 5600 |
| 5600 | 5601 |
| 5601 void Heap::EnableInlineAllocation() { | 5602 void Heap::EnableInlineAllocation() { |
| 5602 if (!inline_allocation_disabled_) return; | 5603 if (!inline_allocation_disabled_) return; |
| (...skipping 1207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6810 *object_type = "CODE_TYPE"; \ | 6811 *object_type = "CODE_TYPE"; \ |
| 6811 *object_sub_type = "CODE_AGE/" #name; \ | 6812 *object_sub_type = "CODE_AGE/" #name; \ |
| 6812 return true; | 6813 return true; |
| 6813 CODE_AGE_LIST_COMPLETE(COMPARE_AND_RETURN_NAME) | 6814 CODE_AGE_LIST_COMPLETE(COMPARE_AND_RETURN_NAME) |
| 6814 #undef COMPARE_AND_RETURN_NAME | 6815 #undef COMPARE_AND_RETURN_NAME |
| 6815 } | 6816 } |
| 6816 return false; | 6817 return false; |
| 6817 } | 6818 } |
| 6818 } // namespace internal | 6819 } // namespace internal |
| 6819 } // namespace v8 | 6820 } // namespace v8 |
| OLD | NEW |