-
Notifications
You must be signed in to change notification settings - Fork 130
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[cc] Simplify and adjust memory limits on Android
On Android, compositor memory limits are derived from system memory and dalvik memory limits. This code was noted as outdated in 2017 (see linked bug), and as a result didn't work the way it should have. This is because: - Reported system RAM on Android is lower than installed RAM because of carveouts - Dalvik memory limits are not really correlated with system RAM Based on field data, the large majority of devices is running with a computed limit of 256MiB, with some devices using 96MiB. This CL simplifies the code to: - Low-end or <2GiB: 96MiB - Otherwise, 256MiB Which mostly matches the current in-the-wild reality. These limits are likely not optimal, but at least this simplifies the code. Also, lower the priority cutoff to "NICE_TO_HAVE", which matches desktop, and reality, since ALLOW_EVERYTHING is lowered to NICE_TO_HAVE elsewhere in the code (see PriorityCutoffToTileMemoryLimitPolicy() for instance). This is gated behind a feature flag, to make sure that this is not breaking things. (cherry picked from commit 42b97eaa9deace1c188434ccac37ee22223ade4f) Bug: 380310632 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/4860245
- Loading branch information
1 parent
8e80e03
commit e663c95
Showing
1 changed file
with
75 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters