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

Unified Diff: gpu/command_buffer/service/gpu_preferences.cc

Issue 2921653005: GLES ProgramCache listens to memory pressure (Closed)
Patch Set: change limits. Created 3 years, 6 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
Index: gpu/command_buffer/service/gpu_preferences.cc
diff --git a/gpu/command_buffer/service/gpu_preferences.cc b/gpu/command_buffer/service/gpu_preferences.cc
index 06bc6b41cb905b3b93b7bf2b919d9668adf47830..86b49b43640f6822a5014bbff8b19357da135277 100644
--- a/gpu/command_buffer/service/gpu_preferences.cc
+++ b/gpu/command_buffer/service/gpu_preferences.cc
@@ -4,9 +4,14 @@
#include "gpu/command_buffer/service/gpu_preferences.h"
+#include "base/sys_info.h"
+
namespace gpu {
GpuPreferences::GpuPreferences() {
+ gpu_program_cache_size = kDefaultMaxProgramCacheMemoryBytes;
+ if (base::SysInfo::IsLowEndDevice())
+ gpu_program_cache_size = kLowEndMaxProgramCacheMemoryBytes;
}
GpuPreferences::GpuPreferences(const GpuPreferences& other) = default;

Powered by Google App Engine
This is Rietveld 408576698