diff options
author | Merry <git@mary.rs> | 2022-04-07 20:32:40 +0200 |
---|---|---|
committer | Merry <git@mary.rs> | 2022-04-07 20:44:07 +0200 |
commit | bbc585881a69b899bfaa9c2982c87a2034d4331e (patch) | |
tree | aa24a84a9a885da4a112d943ec267b02bba83e39 /src/video_core/gpu.cpp | |
parent | input_common: Replace lock_guard with scoped_lock (diff) | |
download | yuzu-bbc585881a69b899bfaa9c2982c87a2034d4331e.tar yuzu-bbc585881a69b899bfaa9c2982c87a2034d4331e.tar.gz yuzu-bbc585881a69b899bfaa9c2982c87a2034d4331e.tar.bz2 yuzu-bbc585881a69b899bfaa9c2982c87a2034d4331e.tar.lz yuzu-bbc585881a69b899bfaa9c2982c87a2034d4331e.tar.xz yuzu-bbc585881a69b899bfaa9c2982c87a2034d4331e.tar.zst yuzu-bbc585881a69b899bfaa9c2982c87a2034d4331e.zip |
Diffstat (limited to '')
-rw-r--r-- | src/video_core/gpu.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/video_core/gpu.cpp b/src/video_core/gpu.cpp index ba9ba082f..789af452d 100644 --- a/src/video_core/gpu.cpp +++ b/src/video_core/gpu.cpp @@ -230,7 +230,7 @@ struct GPU::Impl { void IncrementSyncPoint(u32 syncpoint_id) { auto& syncpoint = syncpoints.at(syncpoint_id); syncpoint++; - std::lock_guard lock{sync_mutex}; + std::scoped_lock lock{sync_mutex}; sync_cv.notify_all(); auto& interrupt = syncpt_interrupts.at(syncpoint_id); if (!interrupt.empty()) { @@ -252,7 +252,7 @@ struct GPU::Impl { } void RegisterSyncptInterrupt(u32 syncpoint_id, u32 value) { - std::lock_guard lock{sync_mutex}; + std::scoped_lock lock{sync_mutex}; auto& interrupt = syncpt_interrupts.at(syncpoint_id); bool contains = std::any_of(interrupt.begin(), interrupt.end(), [value](u32 in_value) { return in_value == value; }); @@ -263,7 +263,7 @@ struct GPU::Impl { } [[nodiscard]] bool CancelSyncptInterrupt(u32 syncpoint_id, u32 value) { - std::lock_guard lock{sync_mutex}; + std::scoped_lock lock{sync_mutex}; auto& interrupt = syncpt_interrupts.at(syncpoint_id); const auto iter = std::find_if(interrupt.begin(), interrupt.end(), |