Vulkan: Refactor GarbageObject.

Instead of allocating a small bundle for deferred deletion, store a
small triple of {Serial,VkHandle,HandleType}. The HandleType can be
used in a generic way to release the VkHandle, without needing to
store a pointer and use a virtual call.

BUG=angleproject:2200

Change-Id: I30925c2f50fd11dafb1b986ced7d279a7dde827b
Reviewed-on: https://chromium-review.googlesource.com/741163
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Frank Henigman <fjhenigman@chromium.org>
diff --git a/src/libANGLE/renderer/vulkan/RendererVk.cpp b/src/libANGLE/renderer/vulkan/RendererVk.cpp
index 749733b..f97e118 100644
--- a/src/libANGLE/renderer/vulkan/RendererVk.cpp
+++ b/src/libANGLE/renderer/vulkan/RendererVk.cpp
@@ -655,7 +655,7 @@
 
     for (auto &garbage : mGarbage)
     {
-        garbage->destroy(mDevice);
+        garbage.destroy(mDevice);
     }
     mGarbage.clear();
 }
@@ -706,7 +706,7 @@
     size_t freeIndex = 0;
     for (; freeIndex < mGarbage.size(); ++freeIndex)
     {
-        if (!mGarbage[freeIndex]->destroyIfComplete(mDevice, finishedSerial))
+        if (!mGarbage[freeIndex].destroyIfComplete(mDevice, finishedSerial))
             break;
     }