aboutsummaryrefslogtreecommitdiff
path: root/src/video_core/renderer_vulkan/pipeline_statistics.cpp
diff options
context:
space:
mode:
authorMerry <git@mary.rs>2022-04-07 19:32:40 +0100
committerMerry <git@mary.rs>2022-04-07 19:44:07 +0100
commite8a60754e9670edd426646f307cb710c1ee52f87 (patch)
treeaa24a84a9a885da4a112d943ec267b02bba83e39 /src/video_core/renderer_vulkan/pipeline_statistics.cpp
parentb02d74d1130ea89c1534d47f7384e5be400509f9 (diff)
video_core: Replace lock_guard with scoped_lock
Diffstat (limited to 'src/video_core/renderer_vulkan/pipeline_statistics.cpp')
-rw-r--r--src/video_core/renderer_vulkan/pipeline_statistics.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/renderer_vulkan/pipeline_statistics.cpp b/src/video_core/renderer_vulkan/pipeline_statistics.cpp
index bfec931a66..7ccadf0841 100644
--- a/src/video_core/renderer_vulkan/pipeline_statistics.cpp
+++ b/src/video_core/renderer_vulkan/pipeline_statistics.cpp
@@ -57,7 +57,7 @@ void PipelineStatistics::Collect(VkPipeline pipeline) {
stage_stats.basic_block_count = GetUint64(statistic);
}
}
- std::lock_guard lock{mutex};
+ std::scoped_lock lock{mutex};
collected_stats.push_back(stage_stats);
}
}
@@ -66,7 +66,7 @@ void PipelineStatistics::Report() const {
double num{};
Stats total;
{
- std::lock_guard lock{mutex};
+ std::scoped_lock lock{mutex};
for (const Stats& stats : collected_stats) {
total.code_size += stats.code_size;
total.register_count += stats.register_count;