diff options
author | liamwhite <liamwhite@users.noreply.github.com> | 2023-11-29 18:33:41 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-11-29 18:33:41 +0100 |
commit | 91ad6b7098e06948ea386f883ae816ad2cb809be (patch) | |
tree | 92e56b888615d2c100c612ca2c235305b2e8b141 | |
parent | Merge pull request #12154 from liamwhite/more-drivers (diff) | |
parent | video_core: fix mac compile (diff) | |
download | yuzu-91ad6b7098e06948ea386f883ae816ad2cb809be.tar yuzu-91ad6b7098e06948ea386f883ae816ad2cb809be.tar.gz yuzu-91ad6b7098e06948ea386f883ae816ad2cb809be.tar.bz2 yuzu-91ad6b7098e06948ea386f883ae816ad2cb809be.tar.lz yuzu-91ad6b7098e06948ea386f883ae816ad2cb809be.tar.xz yuzu-91ad6b7098e06948ea386f883ae816ad2cb809be.tar.zst yuzu-91ad6b7098e06948ea386f883ae816ad2cb809be.zip |
-rw-r--r-- | src/video_core/buffer_cache/usage_tracker.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/buffer_cache/usage_tracker.h b/src/video_core/buffer_cache/usage_tracker.h index ab05fe415..5f8688d31 100644 --- a/src/video_core/buffer_cache/usage_tracker.h +++ b/src/video_core/buffer_cache/usage_tracker.h @@ -58,7 +58,7 @@ private: void TrackPage(u64 page, u64 offset, u64 size) noexcept { const size_t offset_in_page = offset % PAGE_BYTES; const size_t first_bit = offset_in_page >> BYTES_PER_BIT_SHIFT; - const size_t num_bits = std::min(size, PAGE_BYTES) >> BYTES_PER_BIT_SHIFT; + const size_t num_bits = std::min<size_t>(size, PAGE_BYTES) >> BYTES_PER_BIT_SHIFT; const size_t mask = ~u64{0} >> (64 - num_bits); pages[page] |= (~u64{0} & mask) << first_bit; } @@ -66,7 +66,7 @@ private: bool IsPageUsed(u64 page, u64 offset, u64 size) const noexcept { const size_t offset_in_page = offset % PAGE_BYTES; const size_t first_bit = offset_in_page >> BYTES_PER_BIT_SHIFT; - const size_t num_bits = std::min(size, PAGE_BYTES) >> BYTES_PER_BIT_SHIFT; + const size_t num_bits = std::min<size_t>(size, PAGE_BYTES) >> BYTES_PER_BIT_SHIFT; const size_t mask = ~u64{0} >> (64 - num_bits); const size_t mask2 = (~u64{0} & mask) << first_bit; return (pages[page] & mask2) != 0; |