MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-ValidationLayers / InUse

Method InUse

layers/state_tracker/state_object.cpp:28–42  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

26}
27
28const VulkanTypedHandle* vvl::StateObject::InUse() const {
29 // NOTE: for performance reasons, this method calls up the tree
30 // with the read lock held.
31 auto guard = ReadLockTree();
32 for (auto& item : parent_nodes_) {
33 auto node = item.second.lock();
34 if (!node) {
35 continue;
36 }
37 if (node->InUse()) {
38 return &node->Handle();
39 }
40 }
41 return nullptr;
42}
43
44bool vvl::StateObject::AddParent(StateObject* parent_node) {
45 auto guard = WriteLockTree();

Callers

nothing calls this directly

Calls 2

lockMethod · 0.45
HandleMethod · 0.45

Tested by

no test coverage detected