Flutter Engine
The Flutter Engine
pages.h
Go to the documentation of this 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
3// BSD-style license that can be found in the LICENSE file.
4
5#ifndef RUNTIME_VM_HEAP_PAGES_H_
6#define RUNTIME_VM_HEAP_PAGES_H_
7
8#include "platform/atomic.h"
9#include "vm/globals.h"
10#include "vm/heap/freelist.h"
11#include "vm/heap/page.h"
12#include "vm/heap/spaces.h"
13#include "vm/lockers.h"
14#include "vm/ring_buffer.h"
15#include "vm/thread.h"
16#include "vm/virtual_memory.h"
17
18namespace dart {
19
20DECLARE_FLAG(bool, write_protect_code);
21
22// Forward declarations.
23class Heap;
24class JSONObject;
26class ObjectSet;
27class ForwardingPage;
28class GCMarker;
29
30// The history holds the timing information of the last garbage collection
31// runs.
33 public:
36
37 void AddGarbageCollectionTime(int64_t start, int64_t end);
38
40
41 bool IsEmpty() const { return history_.Size() == 0; }
42
43 private:
44 struct Entry {
45 int64_t start;
46 int64_t end;
47 };
48 static constexpr intptr_t kHistoryLength = 4;
49 RingBuffer<Entry, kHistoryLength> history_;
50
51 DISALLOW_ALLOCATION();
52 DISALLOW_COPY_AND_ASSIGN(PageSpaceGarbageCollectionHistory);
53};
54
55// PageSpaceController controls the heap size.
57 public:
58 // The heap is passed in for recording stats only. The controller does not
59 // invoke GC by itself.
61 int heap_growth_ratio,
62 int heap_growth_max,
63 int garbage_collection_time_ratio);
65
66 // Returns whether growing to 'after' should trigger a GC.
67 // This method can be called before allocation (e.g., pretenuring) or after
68 // (e.g., promotion), as it does not change the state of the controller.
69 bool ReachedHardThreshold(SpaceUsage after) const;
70 bool ReachedSoftThreshold(SpaceUsage after) const;
71
72 // Returns whether an idle GC is worthwhile.
73 bool ReachedIdleThreshold(SpaceUsage current) const;
74
75 // Should be called after each collection to update the controller state.
77 SpaceUsage after,
78 int64_t start,
79 int64_t end);
81
82 void set_last_usage(SpaceUsage current) { last_usage_ = current; }
83
84 private:
85 friend class PageSpace; // For MergeOtherPageSpaceController
86
87 void RecordUpdate(SpaceUsage before, SpaceUsage after, const char* reason);
88 void RecordUpdate(SpaceUsage before,
89 SpaceUsage after,
90 intptr_t growth_in_pages,
91 const char* reason);
92
93 Heap* heap_;
94
95 // Usage after last evaluated GC or last enabled.
96 SpaceUsage last_usage_;
97
98 // If the garbage collector was not able to free more than heap_growth_ratio_
99 // memory, then the heap is grown. Otherwise garbage collection is performed.
100 const int heap_growth_ratio_;
101
102 // The desired percent of heap in-use after a garbage collection.
103 // Equivalent to \frac{100-heap_growth_ratio_}{100}.
104 const double desired_utilization_;
105
106 // Max number of pages we grow.
107 const int heap_growth_max_;
108
109 // If the relative GC time goes above garbage_collection_time_ratio_ %,
110 // we grow the heap more aggressively.
111 const int garbage_collection_time_ratio_;
112
113 // Perform a stop-the-world GC when usage exceeds this amount.
114 intptr_t hard_gc_threshold_in_words_;
115
116 // Begin concurrent marking when usage exceeds this amount.
117 intptr_t soft_gc_threshold_in_words_;
118
119 // Run idle GC if time permits when usage exceeds this amount.
120 intptr_t idle_gc_threshold_in_words_;
121
123
125};
126
128 public:
130 enum Phase {
136 };
137
138 PageSpace(Heap* heap, intptr_t max_capacity_in_words);
139 ~PageSpace();
140
142 bool is_executable = false,
143 GrowthPolicy growth_policy = kControlGrowth) {
144 bool is_protected = (is_executable) && FLAG_write_protect_code;
145 bool is_locked = false;
146 return TryAllocateInternal(
147 size, &freelists_[is_executable ? kExecutableFreelist : kDataFreelist],
148 is_executable, growth_policy, is_protected, is_locked);
149 }
150 DART_FORCE_INLINE
154 if (freelist->TryAllocateBumpLocked(size, &result)) {
155 return result;
156 }
157 }
158 return TryAllocatePromoLockedSlow(freelist, size);
159 }
160 DART_FORCE_INLINE
164 if (freelist->TryAllocateBumpLocked(size, &result)) {
165 return result;
166 }
167 }
168 return AllocateSnapshotLockedSlow(freelist, size);
169 }
170
172 bool MarkReservation();
173 void TryReserveForOOM();
174 void VisitRoots(ObjectPointerVisitor* visitor);
175
176 bool ReachedHardThreshold() const {
177 return page_space_controller_.ReachedHardThreshold(usage_);
178 }
179 bool ReachedSoftThreshold() const {
180 return page_space_controller_.ReachedSoftThreshold(usage_);
181 }
182 bool ReachedIdleThreshold() const {
183 return page_space_controller_.ReachedIdleThreshold(usage_);
184 }
186 page_space_controller_.EvaluateAfterLoading(usage_);
187
188 MutexLocker ml(&pages_lock_);
189 for (Page* page = pages_; page != nullptr; page = page->next()) {
190 page->set_never_evacuate(true);
191 }
192 }
193
194 intptr_t UsedInWords() const { return usage_.used_in_words; }
195 intptr_t CapacityInWords() const {
196 MutexLocker ml(&pages_lock_);
197 return usage_.capacity_in_words;
198 }
199 void IncreaseCapacityInWords(intptr_t increase_in_words) {
200 MutexLocker ml(&pages_lock_);
201 IncreaseCapacityInWordsLocked(increase_in_words);
202 }
203 void IncreaseCapacityInWordsLocked(intptr_t increase_in_words) {
205 usage_.capacity_in_words += increase_in_words;
207 }
208
210 void UpdateMaxUsed();
211
212 intptr_t ExternalInWords() const { return usage_.external_in_words; }
214 MutexLocker ml(&pages_lock_);
215 return usage_;
216 }
217 intptr_t ImageInWords() const {
218 intptr_t size = 0;
219 MutexLocker ml(&pages_lock_);
220 for (Page* page = image_pages_; page != nullptr; page = page->next()) {
221 size += page->memory_->size();
222 }
223 return size >> kWordSizeLog2;
224 }
225
226 bool Contains(uword addr) const;
227 bool ContainsUnsafe(uword addr) const;
228 bool CodeContains(uword addr) const;
229 bool DataContains(uword addr) const;
230 bool IsValidAddress(uword addr) const { return Contains(addr); }
231
232 void VisitObjects(ObjectVisitor* visitor) const;
233 void VisitObjectsNoImagePages(ObjectVisitor* visitor) const;
234 void VisitObjectsImagePages(ObjectVisitor* visitor) const;
235 void VisitObjectsUnsafe(ObjectVisitor* visitor) const;
236 void VisitObjectPointers(ObjectPointerVisitor* visitor) const;
237
239 void ResetProgressBars() const;
240
241 // Collect the garbage in the page space using mark-sweep or mark-compact.
242 void CollectGarbage(Thread* thread, bool compact, bool finalize);
243
245
246 // Note: Code pages are made executable/non-executable when 'read_only' is
247 // true/false, respectively.
248 void WriteProtect(bool read_only);
249 void WriteProtectCode(bool read_only);
250
251 bool ShouldStartIdleMarkSweep(int64_t deadline);
252 bool ShouldPerformIdleMarkCompact(int64_t deadline);
253 void IncrementalMarkWithSizeBudget(intptr_t size);
254 void IncrementalMarkWithTimeBudget(int64_t deadline);
255 void AssistTasks(MonitorLocker* ml);
256
257 void AddGCTime(int64_t micros) { gc_time_micros_ += micros; }
258
259 int64_t gc_time_micros() const { return gc_time_micros_; }
260
261 void IncrementCollections() { collections_++; }
262
263 intptr_t collections() const { return collections_; }
264
265#ifndef PRODUCT
266 void PrintToJSONObject(JSONObject* object) const;
267 void PrintHeapMapToJSONStream(IsolateGroup* isolate_group,
268 JSONStream* stream) const;
269#endif // PRODUCT
270
271 void AllocateBlack(intptr_t size) {
272 allocated_black_in_words_.fetch_add(size >> kWordSizeLog2);
273 }
274
275 // Tracks an external allocation by incrementing the old space's total
276 // external size tracker. Returns false without incrementing the tracker if
277 // this allocation will make it exceed kMaxAddrSpaceInWords.
278 bool AllocatedExternal(intptr_t size) {
279 ASSERT(size >= 0);
280 intptr_t size_in_words = size >> kWordSizeLog2;
281 intptr_t expected = usage_.external_in_words.load();
282 intptr_t desired;
283 do {
284 desired = expected + size_in_words;
285 if (desired < 0 || desired > kMaxAddrSpaceInWords) {
286 return false;
287 }
288 ASSERT(desired >= 0);
289 } while (
290 !usage_.external_in_words.compare_exchange_weak(expected, desired));
291 return true;
292 }
293 void FreedExternal(intptr_t size) {
294 ASSERT(size >= 0);
295 intptr_t size_in_words = size >> kWordSizeLog2;
296 usage_.external_in_words -= size_in_words;
297 ASSERT(usage_.external_in_words >= 0);
298 }
299
300 // Bulk data allocation.
301 FreeList* DataFreeList(intptr_t i = 0) {
302 return &freelists_[kDataFreelist + i];
303 }
304 void AcquireLock(FreeList* freelist);
305 void ReleaseLock(FreeList* freelist);
306
311 pause_concurrent_marking_.fetch_or(0);
312 }
313
314 Monitor* tasks_lock() const { return &tasks_lock_; }
315 intptr_t tasks() const { return tasks_; }
316 void set_tasks(intptr_t val) {
317 ASSERT(val >= 0);
318 tasks_ = val;
319 }
320 intptr_t concurrent_marker_tasks() const {
322 return concurrent_marker_tasks_;
323 }
324 void set_concurrent_marker_tasks(intptr_t val) {
325 ASSERT(val >= 0);
327 concurrent_marker_tasks_ = val;
328 }
331 return concurrent_marker_tasks_active_;
332 }
334 ASSERT(val >= 0);
336 concurrent_marker_tasks_active_ = val;
337 }
339 return pause_concurrent_marking_.load() != 0;
340 }
341 Phase phase() const { return phase_; }
342 void set_phase(Phase val) { phase_ = val; }
343
344 void SetupImagePage(void* pointer, uword size, bool is_executable);
345
346 // Return any bump allocation block to the freelist.
348 // Have threads release marking stack blocks, etc.
350
351 bool enable_concurrent_mark() const { return enable_concurrent_mark_; }
353 enable_concurrent_mark_ = enable_concurrent_mark;
354 }
355
357
358 GCMarker* marker() const { return marker_; }
359
360 private:
361 // Ids for time and data records in Heap::GCStats.
362 enum {
363 // Time
364 kConcurrentSweep = 0,
365 kSafePoint = 1,
366 kMarkObjects = 2,
367 kResetFreeLists = 3,
368 kSweepPages = 4,
369 kSweepLargePages = 5,
370 };
371
372 uword TryAllocateDataLocked(FreeList* freelist,
373 intptr_t size,
374 GrowthPolicy growth_policy) {
375 bool is_executable = false;
376 bool is_protected = false;
377 bool is_locked = true;
378 return TryAllocateInternal(size, freelist, is_executable, growth_policy,
379 is_protected, is_locked);
380 }
381 uword TryAllocateInternal(intptr_t size,
382 FreeList* freelist,
383 bool is_executable,
384 GrowthPolicy growth_policy,
385 bool is_protected,
386 bool is_locked);
387 uword TryAllocateInFreshPage(intptr_t size,
388 FreeList* freelist,
389 bool is_executable,
390 GrowthPolicy growth_policy,
391 bool is_locked);
392 uword TryAllocateInFreshLargePage(intptr_t size,
393 bool is_executable,
394 GrowthPolicy growth_policy);
395
396 // Attempt to allocate from bump block rather than normal freelist.
397 uword TryAllocateDataBumpLocked(FreeList* freelist, intptr_t size);
398 uword TryAllocatePromoLockedSlow(FreeList* freelist, intptr_t size);
399 uword AllocateSnapshotLockedSlow(FreeList* freelist, intptr_t size);
400
401 // Makes bump block walkable; do not call concurrently with mutator.
402 void MakeIterable() const;
403
404 void AddPageLocked(Page* page);
405 void AddLargePageLocked(Page* page);
406 void AddExecPageLocked(Page* page);
407 void RemovePageLocked(Page* page, Page* previous_page);
408 void RemoveLargePageLocked(Page* page, Page* previous_page);
409 void RemoveExecPageLocked(Page* page, Page* previous_page);
410
411 Page* AllocatePage(bool is_executable, bool link = true);
412 Page* AllocateLargePage(intptr_t size, bool is_executable);
413
414 void TruncateLargePage(Page* page, intptr_t new_object_size_in_bytes);
415 void FreePage(Page* page, Page* previous_page);
416 void FreeLargePage(Page* page, Page* previous_page);
417 void FreePages(Page* pages);
418
419 void CollectGarbageHelper(Thread* thread, bool compact, bool finalize);
420 void VerifyStoreBuffers(const char* msg);
421 void SweepNew();
422 void SweepLarge();
423 void Sweep(bool exclusive);
424 void ConcurrentSweep(IsolateGroup* isolate_group);
425 void Compact(Thread* thread);
426
427 static intptr_t LargePageSizeInWordsFor(intptr_t size);
428
429 bool CanIncreaseCapacityInWordsLocked(intptr_t increase_in_words) {
430 if (max_capacity_in_words_ == 0) {
431 // Unlimited.
432 return true;
433 }
434 intptr_t free_capacity_in_words =
435 (max_capacity_in_words_ - usage_.capacity_in_words);
436 return ((free_capacity_in_words > 0) &&
437 (increase_in_words <= free_capacity_in_words));
438 }
439
440 Heap* const heap_;
441
442 // One list for executable pages at freelists_[kExecutableFreelist].
443 // FLAG_scavenger_tasks count of lists for data pages starting at
444 // freelists_[kDataFreelist]. The sweeper inserts into the data page
445 // freelists round-robin. The scavenger workers each use one of the data
446 // page freelists without locking.
447 const intptr_t num_freelists_;
448 enum {
449 kExecutableFreelist = 0,
450 kDataFreelist = 1,
451 };
452 FreeList* freelists_;
453 static constexpr intptr_t kOOMReservationSize = 32 * KB;
454 FreeListElement* oom_reservation_ = nullptr;
455
456 // Use ExclusivePageIterator for safe access to these.
457 mutable Mutex pages_lock_;
458 Page* pages_ = nullptr;
459 Page* pages_tail_ = nullptr;
460 Page* exec_pages_ = nullptr;
461 Page* exec_pages_tail_ = nullptr;
462 Page* large_pages_ = nullptr;
463 Page* large_pages_tail_ = nullptr;
464 Page* image_pages_ = nullptr;
465 Page* sweep_regular_ = nullptr;
466 Page* sweep_large_ = nullptr;
467
468 // Various sizes being tracked for this generation.
469 intptr_t max_capacity_in_words_;
470
471 // NOTE: The capacity component of usage_ is updated by the concurrent
472 // sweeper. Use (Increase)CapacityInWords(Locked) for thread-safe access.
473 SpaceUsage usage_;
474 RelaxedAtomic<intptr_t> allocated_black_in_words_;
475
476 // Keep track of running MarkSweep tasks.
477 mutable Monitor tasks_lock_;
478 intptr_t tasks_;
479 intptr_t concurrent_marker_tasks_;
480 intptr_t concurrent_marker_tasks_active_;
481 AcqRelAtomic<uword> pause_concurrent_marking_;
482 Phase phase_;
483
484#if defined(DEBUG)
485 Thread* iterating_thread_;
486#endif
487 PageSpaceController page_space_controller_;
488 GCMarker* marker_;
489
490 int64_t gc_time_micros_;
491 intptr_t collections_;
492 intptr_t mark_words_per_micro_;
493
494 bool enable_concurrent_mark_;
495
496 friend class BasePageIterator;
500 friend class HeapIterationScope;
501 friend class HeapSnapshotWriter;
504 friend class GCCompactor;
506 friend class PrologueTask;
507 friend class EpilogueTask;
508 friend class CompactorTask;
509 friend class Code;
510
512};
513
514} // namespace dart
515
516#endif // RUNTIME_VM_HEAP_PAGES_H_
#define DEBUG_ASSERT(cond)
Definition: assert.h:321
T fetch_or(T arg, std::memory_order order=std::memory_order_acq_rel)
Definition: atomic.h:114
T load(std::memory_order order=std::memory_order_acquire) const
Definition: atomic.h:101
DART_FORCE_INLINE bool TryAllocateBumpLocked(intptr_t size, uword *result)
Definition: freelist.h:122
bool IsOwnedByCurrentThread() const
Definition: os_thread.h:371
bool IsOwnedByCurrentThread() const
Definition: os_thread.h:402
bool ReachedSoftThreshold(SpaceUsage after) const
Definition: pages.cc:1582
bool ReachedHardThreshold(SpaceUsage after) const
Definition: pages.cc:1572
bool ReachedIdleThreshold(SpaceUsage current) const
Definition: pages.cc:1592
void set_last_usage(SpaceUsage current)
Definition: pages.h:82
void EvaluateAfterLoading(SpaceUsage after)
Definition: pages.cc:1704
void EvaluateGarbageCollection(SpaceUsage before, SpaceUsage after, int64_t start, int64_t end)
Definition: pages.cc:1599
PageSpaceController(Heap *heap, int heap_growth_ratio, int heap_growth_max, int garbage_collection_time_ratio)
Definition: pages.cc:1556
void AddGarbageCollectionTime(int64_t start, int64_t end)
Definition: pages.cc:1774
void set_concurrent_marker_tasks_active(intptr_t val)
Definition: pages.h:333
void WriteProtectCode(bool read_only)
Definition: pages.cc:812
FreeList * DataFreeList(intptr_t i=0)
Definition: pages.h:301
void PrintHeapMapToJSONStream(IsolateGroup *isolate_group, JSONStream *stream) const
Definition: pages.cc:772
intptr_t UsedInWords() const
Definition: pages.h:194
bool ReachedSoftThreshold() const
Definition: pages.h:179
void AllocateBlack(intptr_t size)
Definition: pages.h:271
intptr_t concurrent_marker_tasks_active() const
Definition: pages.h:329
bool ShouldStartIdleMarkSweep(int64_t deadline)
Definition: pages.cc:833
intptr_t tasks() const
Definition: pages.h:315
void IncrementalMarkWithSizeBudget(intptr_t size)
Definition: pages.cc:905
void AddGCTime(int64_t micros)
Definition: pages.h:257
DART_FORCE_INLINE uword TryAllocatePromoLocked(FreeList *freelist, intptr_t size)
Definition: pages.h:151
bool Contains(uword addr) const
Definition: pages.cc:607
int64_t gc_time_micros() const
Definition: pages.h:259
void WriteProtect(bool read_only)
Definition: pages.cc:722
uword TryAllocate(intptr_t size, bool is_executable=false, GrowthPolicy growth_policy=kControlGrowth)
Definition: pages.h:141
void TryReleaseReservation()
Definition: pages.cc:931
void AcquireLock(FreeList *freelist)
Definition: pages.cc:432
bool ReachedIdleThreshold() const
Definition: pages.h:182
void IncrementCollections()
Definition: pages.h:261
bool ShouldPerformIdleMarkCompact(int64_t deadline)
Definition: pages.cc:860
PageSpace(Heap *heap, intptr_t max_capacity_in_words)
Definition: pages.cc:55
void PushDependencyToConcurrentMarking()
Definition: pages.h:310
bool pause_concurrent_marking() const
Definition: pages.h:338
friend class ExclusiveLargePageIterator
Definition: pages.h:499
void set_tasks(intptr_t val)
Definition: pages.h:316
bool enable_concurrent_mark() const
Definition: pages.h:351
void set_concurrent_marker_tasks(intptr_t val)
Definition: pages.h:324
@ kAwaitingFinalization
Definition: pages.h:133
@ kSweepingRegular
Definition: pages.h:135
@ kSweepingLarge
Definition: pages.h:134
void IncrementalMarkWithTimeBudget(int64_t deadline)
Definition: pages.cc:911
intptr_t collections() const
Definition: pages.h:263
void VisitObjects(ObjectVisitor *visitor) const
Definition: pages.cc:651
void CollectGarbage(Thread *thread, bool compact, bool finalize)
Definition: pages.cc:974
void ReleaseLock(FreeList *freelist)
Definition: pages.cc:436
void VisitObjectsNoImagePages(ObjectVisitor *visitor) const
Definition: pages.cc:657
void UpdateMaxCapacityLocked()
Definition: pages.cc:592
SpaceUsage GetCurrentUsage() const
Definition: pages.h:213
bool DataContains(uword addr) const
Definition: pages.cc:634
void IncreaseCapacityInWordsLocked(intptr_t increase_in_words)
Definition: pages.h:203
bool ReachedHardThreshold() const
Definition: pages.h:176
bool CodeContains(uword addr) const
Definition: pages.cc:625
void EvaluateAfterLoading()
Definition: pages.h:185
void VisitRememberedCards(PredicateObjectPointerVisitor *visitor) const
Definition: pages.cc:685
bool MarkReservation()
Definition: pages.cc:941
friend class HeapSnapshotWriter
Definition: pages.h:501
DART_FORCE_INLINE uword AllocateSnapshotLocked(FreeList *freelist, intptr_t size)
Definition: pages.h:161
void ReleaseBumpAllocation()
Definition: pages.cc:580
bool ContainsUnsafe(uword addr) const
Definition: pages.cc:616
intptr_t ImageInWords() const
Definition: pages.h:217
void SetupImagePage(void *pointer, uword size, bool is_executable)
Definition: pages.cc:1509
void UpdateMaxUsed()
Definition: pages.cc:600
intptr_t CapacityInWords() const
Definition: pages.h:195
void ResumeConcurrentMarking()
Definition: pages.cc:452
intptr_t concurrent_marker_tasks() const
Definition: pages.h:320
void YieldConcurrentMarking()
Definition: pages.cc:459
void AddRegionsToObjectSet(ObjectSet *set) const
Definition: pages.cc:643
void AbandonMarkingForShutdown()
Definition: pages.cc:587
void FreedExternal(intptr_t size)
Definition: pages.h:293
void PrintToJSONObject(JSONObject *object) const
Definition: pages.cc:735
@ kControlGrowth
Definition: pages.h:129
void VisitObjectsImagePages(ObjectVisitor *visitor) const
Definition: pages.cc:665
void set_phase(Phase val)
Definition: pages.h:342
void TryReserveForOOM()
Definition: pages.cc:952
bool AllocatedExternal(intptr_t size)
Definition: pages.h:278
void IncreaseCapacityInWords(intptr_t increase_in_words)
Definition: pages.h:199
void PauseConcurrentMarking()
Definition: pages.cc:443
bool IsValidAddress(uword addr) const
Definition: pages.h:230
bool IsObjectFromImagePages(ObjectPtr object)
Definition: pages.cc:1544
void ResetProgressBars() const
Definition: pages.cc:716
void AssistTasks(MonitorLocker *ml)
Definition: pages.cc:917
void VisitRoots(ObjectPointerVisitor *visitor)
Definition: pages.cc:962
Monitor * tasks_lock() const
Definition: pages.h:314
void VisitObjectPointers(ObjectPointerVisitor *visitor) const
Definition: pages.cc:679
intptr_t ExternalInWords() const
Definition: pages.h:212
GCMarker * marker() const
Definition: pages.h:358
void set_enable_concurrent_mark(bool enable_concurrent_mark)
Definition: pages.h:352
friend class PageSpaceController
Definition: pages.h:502
void VisitObjectsUnsafe(ObjectVisitor *visitor) const
Definition: pages.cc:673
Phase phase() const
Definition: pages.h:341
T load(std::memory_order order=std::memory_order_relaxed) const
Definition: atomic.h:21
T fetch_add(T arg, std::memory_order order=std::memory_order_relaxed)
Definition: atomic.h:35
bool compare_exchange_weak(T &expected, T desired, std::memory_order order=std::memory_order_relaxed)
Definition: atomic.h:52
int64_t Size() const
Definition: ring_buffer.h:28
RelaxedAtomic< intptr_t > external_in_words
Definition: spaces.h:22
RelaxedAtomic< intptr_t > capacity_in_words
Definition: spaces.h:20
RelaxedAtomic< intptr_t > used_in_words
Definition: spaces.h:21
#define ASSERT(E)
glong glong end
GAsyncResult * result
def link(from_root, to_root)
Definition: dart_pkg.py:44
Definition: dart_vm.cc:33
constexpr intptr_t kWordSizeLog2
Definition: globals.h:507
constexpr intptr_t KB
Definition: globals.h:528
uintptr_t uword
Definition: globals.h:501
bool IsAllocatableViaFreeLists(intptr_t size)
Definition: spaces.h:60
const intptr_t kMaxAddrSpaceInWords
Definition: globals.h:50
DECLARE_FLAG(bool, show_invisible_frames)
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
Definition: switches.h:259
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir Path to the cache directory This is different from the persistent_cache_path in embedder which is used for Skia shader cache icu native lib Path to the library file that exports the ICU data vm service The hostname IP address on which the Dart VM Service should be served If not set
Definition: switches.h:76
#define LIKELY(cond)
Definition: globals.h:260
#define DISALLOW_IMPLICIT_CONSTRUCTORS(TypeName)
Definition: globals.h:593