diff options
author | robertphillips <robertphillips@google.com> | 2016-08-18 14:01:14 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-08-18 14:01:14 -0700 |
commit | 48d91b52e4eb27f6bcb8eadb68558707a3c30875 (patch) | |
tree | c93e2bcad19903e00192e442db52c6aa1f9fc580 /src/gpu/GrBufferAllocPool.cpp | |
parent | 93242c4ae50dfcc0d922cdb3ba80bbc7b4bbe93d (diff) |
Delay creation of cpu-side buffer memory until actually needed
IIUC what is going on, this won't really do anything bad but will defer allocation of the cpu-side buffer until it is actually needed.
BUG=635015
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2248283007
Review-Url: https://codereview.chromium.org/2248283007
Diffstat (limited to 'src/gpu/GrBufferAllocPool.cpp')
-rw-r--r-- | src/gpu/GrBufferAllocPool.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/gpu/GrBufferAllocPool.cpp b/src/gpu/GrBufferAllocPool.cpp index bb73a101ee..e3f30b0c1c 100644 --- a/src/gpu/GrBufferAllocPool.cpp +++ b/src/gpu/GrBufferAllocPool.cpp @@ -78,10 +78,7 @@ void GrBufferAllocPool::reset() { VALIDATE(); fBytesInUse = 0; this->deleteBlocks(); - - // we may have created a large cpu mirror of a large VB. Reset the size to match our minimum. - this->resetCpuData(fMinBlockSize); - + this->resetCpuData(0); // delete all the cpu-side memory VALIDATE(); } |