Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(576)

Unified Diff: src/heap/heap.h

Issue 1208993009: Reland "Replace reduce-memory mode in idle notification with delayed clean-up GC." (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/heap/gc-idle-time-handler.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/heap.h
diff --git a/src/heap/heap.h b/src/heap/heap.h
index be280a0a7a3bc0af8d3ea44482beb0831fa4ec7b..2db6923d684720c491939d3589bb5519d130a5ba 100644
--- a/src/heap/heap.h
+++ b/src/heap/heap.h
@@ -16,6 +16,7 @@
#include "src/heap/gc-tracer.h"
#include "src/heap/incremental-marking.h"
#include "src/heap/mark-compact.h"
+#include "src/heap/memory-reducer.h"
#include "src/heap/objects-visiting.h"
#include "src/heap/spaces.h"
#include "src/heap/store-buffer.h"
@@ -832,6 +833,10 @@ class Heap {
// Notify the heap that a context has been disposed.
int NotifyContextDisposed(bool dependant_context);
+ // Start incremental marking and ensure that idle time handler can perform
+ // incremental steps.
+ void StartIdleIncrementalMarking();
+
inline void increment_scan_on_scavenge_pages() {
scan_on_scavenge_pages_++;
if (FLAG_gc_verbose) {
@@ -1618,6 +1623,10 @@ class Heap {
// An ArrayBuffer moved from new space to old space.
void PromoteArrayBuffer(Object* buffer);
+ bool HasLowAllocationRate();
+ bool HasHighFragmentation();
+ bool HasHighFragmentation(intptr_t used, intptr_t committed);
+
protected:
// Methods made available to tests.
@@ -1778,10 +1787,6 @@ class Heap {
// generation and on every allocation in large object space.
intptr_t old_generation_allocation_limit_;
- // The allocation limit when there is >16.66ms idle time in the idle time
- // handler.
- intptr_t idle_old_generation_allocation_limit_;
-
// Indicates that an allocation has failed in the old generation since the
// last GC.
bool old_gen_exhausted_;
@@ -2258,7 +2263,6 @@ class Heap {
bool HasLowYoungGenerationAllocationRate();
bool HasLowOldGenerationAllocationRate();
- bool HasLowAllocationRate();
void ReduceNewSpaceSize();
@@ -2325,6 +2329,8 @@ class Heap {
GCIdleTimeHandler gc_idle_time_handler_;
+ MemoryReducer memory_reducer_;
+
// These two counters are monotomically increasing and never reset.
size_t full_codegen_bytes_generated_;
size_t crankshaft_codegen_bytes_generated_;
« no previous file with comments | « src/heap/gc-idle-time-handler.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698