tqchen commented on a change in pull request #7833:
URL: https://github.com/apache/tvm/pull/7833#discussion_r614248328



##########
File path: src/runtime/vulkan/vulkan.cc
##########
@@ -990,57 +1058,59 @@ Module 
VulkanModuleCreate(std::unordered_map<std::string, VulkanShader> smap,
 
 VulkanThreadEntry* VulkanThreadEntry::ThreadLocal() { return 
VulkanThreadStore::Get(); }
 
-VulkanStagingBuffer* VulkanThreadEntry::StagingBuffer(int device_id, size_t 
size) {
-  if (!staging_buffers_[device_id]) {
-    staging_buffers_[device_id] = std::unique_ptr<VulkanStagingBuffer>(new 
VulkanStagingBuffer());
+VulkanHostVisibleBuffer* GetOrAllocate(

Review comment:
       In the case of staging buffer the sync happens everytime after the copy, 
so it should be fine. So there won't be stale staging buffer(because previous 
copy was synced)




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to