From c80ed6d81fef5858508ac4b841defe8ee3a8663d Mon Sep 17 00:00:00 2001 From: Liam Date: Fri, 19 Aug 2022 21:58:25 -0400 Subject: general: rework usages of UNREACHABLE macro --- src/core/hle/service/nvdrv/devices/nvhost_as_gpu.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/core/hle/service/nvdrv/devices/nvhost_as_gpu.cpp') diff --git a/src/core/hle/service/nvdrv/devices/nvhost_as_gpu.cpp b/src/core/hle/service/nvdrv/devices/nvhost_as_gpu.cpp index 7a95f5305..192503ffc 100644 --- a/src/core/hle/service/nvdrv/devices/nvhost_as_gpu.cpp +++ b/src/core/hle/service/nvdrv/devices/nvhost_as_gpu.cpp @@ -96,7 +96,7 @@ NvResult nvhost_as_gpu::AllocAsEx(const std::vector& input, std::vector& std::scoped_lock lock(mutex); if (vm.initialised) { - UNREACHABLE_MSG("Cannot initialise an address space twice!"); + ASSERT_MSG(false, "Cannot initialise an address space twice!"); return NvResult::InvalidState; } @@ -174,7 +174,7 @@ NvResult nvhost_as_gpu::AllocateSpace(const std::vector& input, std::vector< } else { params.offset = static_cast(allocator.Allocate(params.pages)) << page_size_bits; if (!params.offset) { - UNREACHABLE_MSG("Failed to allocate free space in the GPU AS!"); + ASSERT_MSG(false, "Failed to allocate free space in the GPU AS!"); return NvResult::InsufficientMemory; } } @@ -372,7 +372,7 @@ NvResult nvhost_as_gpu::MapBufferEx(const std::vector& input, std::vectoralign, VM::YUZU_PAGESIZE)) return false; else { - UNREACHABLE(); + ASSERT(false); return false; } }()}; @@ -382,7 +382,7 @@ NvResult nvhost_as_gpu::MapBufferEx(const std::vector& input, std::vectorfirst) + size > alloc->second.size) { - UNREACHABLE_MSG("Cannot perform a fixed mapping into an unallocated region!"); + ASSERT_MSG(false, "Cannot perform a fixed mapping into an unallocated region!"); return NvResult::BadValue; } @@ -403,7 +403,7 @@ NvResult nvhost_as_gpu::MapBufferEx(const std::vector& input, std::vector(Common::AlignUp(size, page_size) >> page_size_bits))) << page_size_bits; if (!params.offset) { - UNREACHABLE_MSG("Failed to allocate free space in the GPU AS!"); + ASSERT_MSG(false, "Failed to allocate free space in the GPU AS!"); return NvResult::InsufficientMemory; } -- cgit v1.2.3