| 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 296 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 307 } | 307 } |
| 308 | 308 |
| 309 void IncrementCollections() { | 309 void IncrementCollections() { |
| 310 collections_++; | 310 collections_++; |
| 311 } | 311 } |
| 312 | 312 |
| 313 intptr_t collections() const { | 313 intptr_t collections() const { |
| 314 return collections_; | 314 return collections_; |
| 315 } | 315 } |
| 316 | 316 |
| 317 #ifndef PRODUCT |
| 317 void PrintToJSONObject(JSONObject* object) const; | 318 void PrintToJSONObject(JSONObject* object) const; |
| 318 void PrintHeapMapToJSONStream(Isolate* isolate, JSONStream* stream) const; | 319 void PrintHeapMapToJSONStream(Isolate* isolate, JSONStream* stream) const; |
| 320 #endif // PRODUCT |
| 319 | 321 |
| 320 void AllocateExternal(intptr_t size); | 322 void AllocateExternal(intptr_t size); |
| 321 void FreeExternal(intptr_t size); | 323 void FreeExternal(intptr_t size); |
| 322 | 324 |
| 323 // Bulk data allocation. | 325 // Bulk data allocation. |
| 324 void AcquireDataLock(); | 326 void AcquireDataLock(); |
| 325 void ReleaseDataLock(); | 327 void ReleaseDataLock(); |
| 326 | 328 |
| 327 uword TryAllocateDataLocked(intptr_t size, GrowthPolicy growth_policy) { | 329 uword TryAllocateDataLocked(intptr_t size, GrowthPolicy growth_policy) { |
| 328 bool is_protected = false; | 330 bool is_protected = false; |
| (...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 454 friend class HeapIterationScope; | 456 friend class HeapIterationScope; |
| 455 friend class PageSpaceController; | 457 friend class PageSpaceController; |
| 456 friend class SweeperTask; | 458 friend class SweeperTask; |
| 457 | 459 |
| 458 DISALLOW_IMPLICIT_CONSTRUCTORS(PageSpace); | 460 DISALLOW_IMPLICIT_CONSTRUCTORS(PageSpace); |
| 459 }; | 461 }; |
| 460 | 462 |
| 461 } // namespace dart | 463 } // namespace dart |
| 462 | 464 |
| 463 #endif // VM_PAGES_H_ | 465 #endif // VM_PAGES_H_ |
| OLD | NEW |