| 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 "vm/freelist.h" | 8 #include "vm/freelist.h" |
| 9 #include "vm/globals.h" | 9 #include "vm/globals.h" |
| 10 #include "vm/lockers.h" | 10 #include "vm/lockers.h" |
| (...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 277 return page_space_controller_.is_enabled(); | 277 return page_space_controller_.is_enabled(); |
| 278 } | 278 } |
| 279 | 279 |
| 280 bool NeedsExternalGC() const { | 280 bool NeedsExternalGC() const { |
| 281 return (max_external_in_words_ != 0) && | 281 return (max_external_in_words_ != 0) && |
| 282 (ExternalInWords() > max_external_in_words_); | 282 (ExternalInWords() > max_external_in_words_); |
| 283 } | 283 } |
| 284 | 284 |
| 285 // Note: Code pages are made executable/non-executable when 'read_only' is | 285 // Note: Code pages are made executable/non-executable when 'read_only' is |
| 286 // true/false, respectively. | 286 // true/false, respectively. |
| 287 void WriteProtect(bool read_only); | 287 void WriteProtect(bool read_only, bool include_code_pages); |
| 288 void WriteProtectCode(bool read_only); | 288 void WriteProtectCode(bool read_only); |
| 289 | 289 |
| 290 void AddGCTime(int64_t micros) { | 290 void AddGCTime(int64_t micros) { |
| 291 gc_time_micros_ += micros; | 291 gc_time_micros_ += micros; |
| 292 } | 292 } |
| 293 | 293 |
| 294 int64_t gc_time_micros() const { | 294 int64_t gc_time_micros() const { |
| 295 return gc_time_micros_; | 295 return gc_time_micros_; |
| 296 } | 296 } |
| 297 | 297 |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 448 friend class HeapIterationScope; | 448 friend class HeapIterationScope; |
| 449 friend class PageSpaceController; | 449 friend class PageSpaceController; |
| 450 friend class SweeperTask; | 450 friend class SweeperTask; |
| 451 | 451 |
| 452 DISALLOW_IMPLICIT_CONSTRUCTORS(PageSpace); | 452 DISALLOW_IMPLICIT_CONSTRUCTORS(PageSpace); |
| 453 }; | 453 }; |
| 454 | 454 |
| 455 } // namespace dart | 455 } // namespace dart |
| 456 | 456 |
| 457 #endif // VM_PAGES_H_ | 457 #endif // VM_PAGES_H_ |
| OLD | NEW |