-
bashi authored
Before this CL, MemoryCoordinatorClient has only one callback called OnMemoryStateChange(). Clients try to free up memory when state change happens (e.g. NORMAL -> SUSPENDED). This may not be a good strategy on some platforms because we may touch compressed pages (see [1] for details). This CL add another callback called OnPurgeMemory() to separate logic for purging existing memory from memory state changes. This way we can build flexible strategies for handling memory pressure. [1] https://groups.google.com/a/chromium.org/forum/?utm_medium=email&utm_source=footer#!msg/project-trim/s96xSirL2Hs/18uq1zfHEgAJ BUG=684287 Review-Url: https://codereview.chromium.org/2655083003 Cr-Commit-Position: refs/heads/master@{#446951}
a7f5cbbe