diff options
author | Lionel Landwerlin <[email protected]> | 2019-07-04 21:55:49 +0300 |
---|---|---|
committer | Lionel Landwerlin <[email protected]> | 2019-07-07 15:47:54 +0300 |
commit | 8f0f727fe4274e222b5a8118c5cb3c7f8cad3d7c (patch) | |
tree | 515f2c81d52a2a4081dcb73367fcc074348a9c3e /src/vulkan/overlay-layer/overlay.cpp | |
parent | 5493ec3c199b3190dc5d247d9e2a0eccd5066cf2 (diff) |
vulkan/overlay: fix command buffer stats
Begin/Reset of command buffer both reset the content of the command
buffer. Don't forget to wipe them on Begin.
Signed-off-by: Lionel Landwerlin <[email protected]>
Fixes: 4438188f492e1f ("vulkan/overlay: record stats in command buffers and accumulate on exec/submit")
Acked-by: Eric Engestrom <[email protected]>
Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src/vulkan/overlay-layer/overlay.cpp')
-rw-r--r-- | src/vulkan/overlay-layer/overlay.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/vulkan/overlay-layer/overlay.cpp b/src/vulkan/overlay-layer/overlay.cpp index a8cba732675..c4344f96aa4 100644 --- a/src/vulkan/overlay-layer/overlay.cpp +++ b/src/vulkan/overlay-layer/overlay.cpp @@ -1843,6 +1843,8 @@ static VkResult overlay_BeginCommandBuffer( struct command_buffer_data *cmd_buffer_data = FIND_CMD_BUFFER_DATA(commandBuffer); struct device_data *device_data = cmd_buffer_data->device; + memset(&cmd_buffer_data->stats, 0, sizeof(cmd_buffer_data->stats)); + /* We don't record any query in secondary command buffers, just make sure * we have the right inheritance. */ |