Skip to content

Commit

Permalink
Remove redundant calls to VulkanCaptureManager::Get() (#1279)
Browse files Browse the repository at this point in the history
The VulkanCaptureManager::Get() function is static and returns a pointer to the
current capture manager instance. While the compiler should inline these calls,
it may fail due to possible aliasing as the instance pointer is not const (but
should never change after setup).
It is better to call get once and explicitly put it in a local variable.

Only vkCreateInstance needs special handling, since it creates the
VulkanCaptureManager in the middle of the function.
  • Loading branch information
charles-lunarg authored Oct 24, 2023
1 parent 77886df commit e4c160d
Show file tree
Hide file tree
Showing 3 changed files with 4,433 additions and 3,212 deletions.
Loading

0 comments on commit e4c160d

Please sign in to comment.