| Index: content/child/memory/child_memory_coordinator_impl.h
|
| diff --git a/content/child/memory/child_memory_coordinator_impl.h b/content/child/memory/child_memory_coordinator_impl.h
|
| index cee8d5a76054309f54ad86056a766a15d5262495..ff75ee8c31ba474f746a9797da2de50ae3026a4d 100644
|
| --- a/content/child/memory/child_memory_coordinator_impl.h
|
| +++ b/content/child/memory/child_memory_coordinator_impl.h
|
| @@ -37,6 +37,21 @@ class CONTENT_EXPORT ChildMemoryCoordinatorImpl
|
|
|
| // mojom::ChildMemoryCoordinator implementations:
|
| void OnStateChange(mojom::MemoryState state) override;
|
| + void SetRemainingGlobalBudget(int64_t remaining_global_budget_mb) override;
|
| +
|
| + // Returns the current memory state of this process.
|
| + mojom::MemoryState GetCurrentMemoryState() const {
|
| + return state_;
|
| + }
|
| +
|
| + // Returns the remaining global budget usable in aggregate by all Chrome
|
| + // processes. This indicates how many MB of memory are remaining for Chrome
|
| + // processes to use before the memory coordinator will take efforts to reclaim
|
| + // memory. A negative amount indicates that the coordinator is actively trying
|
| + // to reclaim that much memory.
|
| + int64_t GetRemainingGlobalBudget() const {
|
| + return remaining_global_budget_mb_;
|
| + }
|
|
|
| protected:
|
| ChildMemoryCoordinatorDelegate* delegate() { return delegate_; }
|
| @@ -48,6 +63,9 @@ class CONTENT_EXPORT ChildMemoryCoordinatorImpl
|
| mojom::MemoryCoordinatorHandlePtr parent_;
|
| ChildMemoryCoordinatorDelegate* delegate_;
|
|
|
| + mojom::MemoryState state_;
|
| + int64_t remaining_global_budget_mb_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(ChildMemoryCoordinatorImpl);
|
| };
|
|
|
|
|