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

Side by Side Diff: gpu/command_buffer/service/gpu_preferences.cc

Issue 2921653005: GLES ProgramCache listens to memory pressure (Closed)
Patch Set: low-end check only on Android. 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "gpu/command_buffer/service/gpu_preferences.h" 5 #include "gpu/command_buffer/service/gpu_preferences.h"
6 6
7 #include "base/sys_info.h"
8
7 namespace gpu { 9 namespace gpu {
8 10
9 GpuPreferences::GpuPreferences() { 11 GpuPreferences::GpuPreferences() {
12 gpu_program_cache_size = kDefaultMaxProgramCacheMemoryBytes;
13 #if defined(OS_ANDROID)
14 if (base::SysInfo::IsLowEndDevice())
15 gpu_program_cache_size = kLowEndMaxProgramCacheMemoryBytes;
16 #endif
10 } 17 }
11 18
12 GpuPreferences::GpuPreferences(const GpuPreferences& other) = default; 19 GpuPreferences::GpuPreferences(const GpuPreferences& other) = default;
13 20
14 GpuPreferences::~GpuPreferences() {} 21 GpuPreferences::~GpuPreferences() {}
15 22
16 } // namespace gpu 23 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/command_buffer/common/constants.h ('k') | gpu/command_buffer/service/memory_program_cache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698