diff options
author | Jeff Bolz <jbolz@nvidia.com> | 2019-08-22 06:10:49 -0500 |
---|---|---|
committer | Mark Lobodzinski <mark@lunarg.com> | 2019-08-22 16:00:21 -0600 |
commit | fd3bb2407100f798059d63002d228dff99e481da (patch) | |
tree | 5fa80266150b2bd841e2dbf5cfe99f8f9e11d903 /scripts | |
parent | 3b9022cae6f59ccacc93a845c5ff2e8fea4f839b (diff) | |
download | vulkan-validation-layers-fd3bb2407100f798059d63002d228dff99e481da.tar.gz |
layers: Use vl_concurrent_unordered_map in ObjectLifetimes
Use vl_concurrent_unordered_map for the object_maps, and remove most use of
the single object_lifetime_mutex. object_lifetime_mutex is still used in a few
cases like to protect access through ObjTrackState::child_objects.
Use shared_ptr for the pointers to ObjTrackState in case of application bugs
like destroying the same object twice, which could otherwise crash when accessing
and freeing that pointer.
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/object_tracker_generator.py | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/scripts/object_tracker_generator.py b/scripts/object_tracker_generator.py index 0f1045cd6..ffb6a9df9 100644 --- a/scripts/object_tracker_generator.py +++ b/scripts/object_tracker_generator.py @@ -963,7 +963,6 @@ class ObjectTrackerOutputGenerator(OutputGenerator): self.appendSection('command', '') self.appendSection('command', pre_cv_func_decl) self.appendSection('command', ' bool skip = false;') - self.appendSection('command', ' auto lock = read_shared_lock();') self.appendSection('command', pre_call_validate) self.appendSection('command', ' return skip;') self.appendSection('command', '}') @@ -973,7 +972,6 @@ class ObjectTrackerOutputGenerator(OutputGenerator): pre_cr_func_decl = 'void ObjectLifetimes::PreCallRecord' + func_decl_template + ' {' self.appendSection('command', '') self.appendSection('command', pre_cr_func_decl) - self.appendSection('command', ' auto lock = write_shared_lock();') self.appendSection('command', pre_call_record) self.appendSection('command', '}') @@ -988,7 +986,6 @@ class ObjectTrackerOutputGenerator(OutputGenerator): if 'CreateGraphicsPipelines' not in cmdname and 'CreateComputePipelines' not in cmdname and 'CreateRayTracingPipelines' not in cmdname: post_cr_func_decl = post_cr_func_decl.replace('{', '{\n if (result != VK_SUCCESS) return;') self.appendSection('command', post_cr_func_decl) - self.appendSection('command', ' auto lock = write_shared_lock();') self.appendSection('command', post_call_record) self.appendSection('command', '}') |