Index: gpu/command_buffer/client/fenced_allocator.cc |
diff --git a/gpu/command_buffer/client/fenced_allocator.cc b/gpu/command_buffer/client/fenced_allocator.cc |
index f105f3a50ea3e23b6045f798831af085aebd3e2b..912c22dd6cbf4e285af07c386593f0eef78f1b6a 100644 |
--- a/gpu/command_buffer/client/fenced_allocator.cc |
+++ b/gpu/command_buffer/client/fenced_allocator.cc |
@@ -130,6 +130,10 @@ bool FencedAllocator::CheckConsistency() { |
return true; |
} |
+bool FencedAllocator::InUse() { |
+ return blocks_.size() != 1 || blocks_[0].state != FREE; |
+} |
+ |
// Collapse the block to the next one, then to the previous one. Provided the |
// structure is consistent, those are the only blocks eligible for collapse. |
FencedAllocator::BlockIndex FencedAllocator::CollapseFreeBlock( |