summaryrefslogtreecommitdiffstats
path: root/gpu
diff options
context:
space:
mode:
authorccameron@chromium.org <ccameron@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-11-01 09:53:35 +0000
committerccameron@chromium.org <ccameron@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-11-01 09:53:35 +0000
commit0b8ef28478075b6b47bddc7d5e75513ca713e0d1 (patch)
tree11a8eb6b32e89d07e69221270be05ca3b2d78151 /gpu
parent7c310d3e5f9f0dcc96cf87c92f7c80dcb3b48179 (diff)
downloadchromium_src-0b8ef28478075b6b47bddc7d5e75513ca713e0d1.zip
chromium_src-0b8ef28478075b6b47bddc7d5e75513ca713e0d1.tar.gz
chromium_src-0b8ef28478075b6b47bddc7d5e75513ca713e0d1.tar.bz2
Do not give GPU memory to backgrounded compositors.
This has already been disabled on all platforms except Windows and Chrome OS to be more conservative about GPU memory. All platforms are moving to a delegated renderer where, if keeping around resources for a fast tab-switch is desired, it can be accomplished by not releasing those resources in the browser process. This feature was originally requested in crbug.com/134750. Also remove the infrastructure for preserving backbuffers of backgrounded renderers. This feature was never enabled. BUG=276559 Review URL: https://codereview.chromium.org/53633003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@232324 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu')
-rw-r--r--gpu/command_buffer/common/gpu_memory_allocation.h22
1 files changed, 3 insertions, 19 deletions
diff --git a/gpu/command_buffer/common/gpu_memory_allocation.h b/gpu/command_buffer/common/gpu_memory_allocation.h
index 3057592..57be4c5 100644
--- a/gpu/command_buffer/common/gpu_memory_allocation.h
+++ b/gpu/command_buffer/common/gpu_memory_allocation.h
@@ -31,36 +31,20 @@ struct MemoryAllocation {
uint64 bytes_limit_when_visible;
PriorityCutoff priority_cutoff_when_visible;
- // Limits when this renderer is not visible.
- uint64 bytes_limit_when_not_visible;
- PriorityCutoff priority_cutoff_when_not_visible;
- bool have_backbuffer_when_not_visible;
-
MemoryAllocation()
: bytes_limit_when_visible(0),
- priority_cutoff_when_visible(CUTOFF_ALLOW_NOTHING),
- bytes_limit_when_not_visible(0),
- priority_cutoff_when_not_visible(CUTOFF_ALLOW_NOTHING),
- have_backbuffer_when_not_visible(false) {
+ priority_cutoff_when_visible(CUTOFF_ALLOW_NOTHING) {
}
MemoryAllocation(uint64 bytes_limit_when_visible)
: bytes_limit_when_visible(bytes_limit_when_visible),
- priority_cutoff_when_visible(CUTOFF_ALLOW_EVERYTHING),
- bytes_limit_when_not_visible(0),
- priority_cutoff_when_not_visible(CUTOFF_ALLOW_NOTHING),
- have_backbuffer_when_not_visible(false) {
+ priority_cutoff_when_visible(CUTOFF_ALLOW_EVERYTHING) {
}
bool Equals(const MemoryAllocation& other) const {
return bytes_limit_when_visible ==
other.bytes_limit_when_visible &&
- priority_cutoff_when_visible == other.priority_cutoff_when_visible &&
- bytes_limit_when_not_visible == other.bytes_limit_when_not_visible &&
- priority_cutoff_when_not_visible ==
- other.priority_cutoff_when_not_visible &&
- have_backbuffer_when_not_visible ==
- other.have_backbuffer_when_not_visible;
+ priority_cutoff_when_visible == other.priority_cutoff_when_visible;
}
};