| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_PAGES_H_ | 5 #ifndef VM_PAGES_H_ |
| 6 #define VM_PAGES_H_ | 6 #define VM_PAGES_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "vm/freelist.h" | 10 #include "vm/freelist.h" |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 128 int64_t start, int64_t end); | 128 int64_t start, int64_t end); |
| 129 | 129 |
| 130 void Enable() { | 130 void Enable() { |
| 131 is_enabled_ = true; | 131 is_enabled_ = true; |
| 132 } | 132 } |
| 133 | 133 |
| 134 private: | 134 private: |
| 135 bool is_enabled_; | 135 bool is_enabled_; |
| 136 | 136 |
| 137 // Heap growth control variable. | 137 // Heap growth control variable. |
| 138 uword grow_heap_; | 138 intptr_t grow_heap_; |
| 139 | 139 |
| 140 // If the garbage collector was not able to free more than heap_growth_ratio_ | 140 // If the garbage collector was not able to free more than heap_growth_ratio_ |
| 141 // memory, then the heap is grown. Otherwise garbage collection is performed. | 141 // memory, then the heap is grown. Otherwise garbage collection is performed. |
| 142 int heap_growth_ratio_; | 142 int heap_growth_ratio_; |
| 143 | 143 |
| 144 // The desired percent of heap in-use after a garbage collection. | 144 // The desired percent of heap in-use after a garbage collection. |
| 145 // Equivalent to \frac{100-heap_growth_ratio_}{100}. | 145 // Equivalent to \frac{100-heap_growth_ratio_}{100}. |
| 146 double desired_utilization_; | 146 double desired_utilization_; |
| 147 | 147 |
| 148 // Number of pages we grow. | 148 // Number of pages we grow. |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 258 bool sweeping_; | 258 bool sweeping_; |
| 259 | 259 |
| 260 PageSpaceController page_space_controller_; | 260 PageSpaceController page_space_controller_; |
| 261 | 261 |
| 262 DISALLOW_IMPLICIT_CONSTRUCTORS(PageSpace); | 262 DISALLOW_IMPLICIT_CONSTRUCTORS(PageSpace); |
| 263 }; | 263 }; |
| 264 | 264 |
| 265 } // namespace dart | 265 } // namespace dart |
| 266 | 266 |
| 267 #endif // VM_PAGES_H_ | 267 #endif // VM_PAGES_H_ |
| OLD | NEW |