diff options
| author | 2022-11-17 19:20:18 -0500 | |
|---|---|---|
| committer | 2022-11-17 19:20:18 -0500 | |
| commit | e5a446a0df56d447e94c9afa98d52ff576a1aa66 (patch) | |
| tree | c0770bffcff6edb00c8ab503a719d3b7ab8a037e /src/video_core | |
| parent | Merge pull request #9228 from HidroSaphire/patch-1 (diff) | |
| parent | Add break for default cases (diff) | |
| download | yuzu-e5a446a0df56d447e94c9afa98d52ff576a1aa66.tar.gz yuzu-e5a446a0df56d447e94c9afa98d52ff576a1aa66.tar.xz yuzu-e5a446a0df56d447e94c9afa98d52ff576a1aa66.zip | |
Merge pull request #9229 from Docteh/achy_breaky_heart
Add break for default cases
Diffstat (limited to 'src/video_core')
| -rw-r--r-- | src/video_core/engines/maxwell_dma.cpp | 1 | ||||
| -rw-r--r-- | src/video_core/engines/puller.cpp | 4 | ||||
| -rw-r--r-- | src/video_core/macro/macro_interpreter.cpp | 2 | ||||
| -rw-r--r-- | src/video_core/macro/macro_jit_x64.cpp | 1 | ||||
| -rw-r--r-- | src/video_core/renderer_opengl/gl_texture_cache.cpp | 2 | ||||
| -rw-r--r-- | src/video_core/renderer_opengl/renderer_opengl.cpp | 1 | ||||
| -rw-r--r-- | src/video_core/renderer_vulkan/vk_scheduler.cpp | 1 | ||||
| -rw-r--r-- | src/video_core/renderer_vulkan/vk_texture_cache.cpp | 1 | ||||
| -rw-r--r-- | src/video_core/textures/decoders.cpp | 3 |
9 files changed, 16 insertions, 0 deletions
diff --git a/src/video_core/engines/maxwell_dma.cpp b/src/video_core/engines/maxwell_dma.cpp index 54523a4b2..1bf6ca2dd 100644 --- a/src/video_core/engines/maxwell_dma.cpp +++ b/src/video_core/engines/maxwell_dma.cpp | |||
| @@ -314,6 +314,7 @@ void MaxwellDMA::ReleaseSemaphore() { | |||
| 314 | } | 314 | } |
| 315 | default: | 315 | default: |
| 316 | ASSERT_MSG(false, "Unknown semaphore type: {}", static_cast<u32>(type.Value())); | 316 | ASSERT_MSG(false, "Unknown semaphore type: {}", static_cast<u32>(type.Value())); |
| 317 | break; | ||
| 317 | } | 318 | } |
| 318 | } | 319 | } |
| 319 | 320 | ||
diff --git a/src/video_core/engines/puller.cpp b/src/video_core/engines/puller.cpp index 3977bb0fb..4d2278811 100644 --- a/src/video_core/engines/puller.cpp +++ b/src/video_core/engines/puller.cpp | |||
| @@ -50,6 +50,7 @@ void Puller::ProcessBindMethod(const MethodCall& method_call) { | |||
| 50 | break; | 50 | break; |
| 51 | default: | 51 | default: |
| 52 | UNIMPLEMENTED_MSG("Unimplemented engine {:04X}", engine_id); | 52 | UNIMPLEMENTED_MSG("Unimplemented engine {:04X}", engine_id); |
| 53 | break; | ||
| 53 | } | 54 | } |
| 54 | } | 55 | } |
| 55 | 56 | ||
| @@ -65,6 +66,7 @@ void Puller::ProcessFenceActionMethod() { | |||
| 65 | break; | 66 | break; |
| 66 | default: | 67 | default: |
| 67 | UNIMPLEMENTED_MSG("Unimplemented operation {}", regs.fence_action.op.Value()); | 68 | UNIMPLEMENTED_MSG("Unimplemented operation {}", regs.fence_action.op.Value()); |
| 69 | break; | ||
| 68 | } | 70 | } |
| 69 | } | 71 | } |
| 70 | 72 | ||
| @@ -228,6 +230,7 @@ void Puller::CallEngineMethod(const MethodCall& method_call) { | |||
| 228 | break; | 230 | break; |
| 229 | default: | 231 | default: |
| 230 | UNIMPLEMENTED_MSG("Unimplemented engine"); | 232 | UNIMPLEMENTED_MSG("Unimplemented engine"); |
| 233 | break; | ||
| 231 | } | 234 | } |
| 232 | } | 235 | } |
| 233 | 236 | ||
| @@ -254,6 +257,7 @@ void Puller::CallEngineMultiMethod(u32 method, u32 subchannel, const u32* base_s | |||
| 254 | break; | 257 | break; |
| 255 | default: | 258 | default: |
| 256 | UNIMPLEMENTED_MSG("Unimplemented engine"); | 259 | UNIMPLEMENTED_MSG("Unimplemented engine"); |
| 260 | break; | ||
| 257 | } | 261 | } |
| 258 | } | 262 | } |
| 259 | 263 | ||
diff --git a/src/video_core/macro/macro_interpreter.cpp b/src/video_core/macro/macro_interpreter.cpp index c0d32c112..0d63495a9 100644 --- a/src/video_core/macro/macro_interpreter.cpp +++ b/src/video_core/macro/macro_interpreter.cpp | |||
| @@ -201,6 +201,7 @@ bool MacroInterpreterImpl::Step(bool is_delay_slot) { | |||
| 201 | } | 201 | } |
| 202 | default: | 202 | default: |
| 203 | UNIMPLEMENTED_MSG("Unimplemented macro operation {}", opcode.operation.Value()); | 203 | UNIMPLEMENTED_MSG("Unimplemented macro operation {}", opcode.operation.Value()); |
| 204 | break; | ||
| 204 | } | 205 | } |
| 205 | 206 | ||
| 206 | // An instruction with the Exit flag will not actually | 207 | // An instruction with the Exit flag will not actually |
| @@ -297,6 +298,7 @@ void MacroInterpreterImpl::ProcessResult(Macro::ResultOperation operation, u32 r | |||
| 297 | break; | 298 | break; |
| 298 | default: | 299 | default: |
| 299 | UNIMPLEMENTED_MSG("Unimplemented result operation {}", operation); | 300 | UNIMPLEMENTED_MSG("Unimplemented result operation {}", operation); |
| 301 | break; | ||
| 300 | } | 302 | } |
| 301 | } | 303 | } |
| 302 | 304 | ||
diff --git a/src/video_core/macro/macro_jit_x64.cpp b/src/video_core/macro/macro_jit_x64.cpp index 25c1ce798..7347cbd88 100644 --- a/src/video_core/macro/macro_jit_x64.cpp +++ b/src/video_core/macro/macro_jit_x64.cpp | |||
| @@ -652,6 +652,7 @@ void MacroJITx64Impl::Compile_ProcessResult(Macro::ResultOperation operation, u3 | |||
| 652 | break; | 652 | break; |
| 653 | default: | 653 | default: |
| 654 | UNIMPLEMENTED_MSG("Unimplemented macro operation {}", operation); | 654 | UNIMPLEMENTED_MSG("Unimplemented macro operation {}", operation); |
| 655 | break; | ||
| 655 | } | 656 | } |
| 656 | } | 657 | } |
| 657 | 658 | ||
diff --git a/src/video_core/renderer_opengl/gl_texture_cache.cpp b/src/video_core/renderer_opengl/gl_texture_cache.cpp index 99cd11d1e..9f7ce7414 100644 --- a/src/video_core/renderer_opengl/gl_texture_cache.cpp +++ b/src/video_core/renderer_opengl/gl_texture_cache.cpp | |||
| @@ -891,6 +891,7 @@ void Image::CopyBufferToImage(const VideoCommon::BufferImageCopy& copy, size_t b | |||
| 891 | break; | 891 | break; |
| 892 | default: | 892 | default: |
| 893 | ASSERT(false); | 893 | ASSERT(false); |
| 894 | break; | ||
| 894 | } | 895 | } |
| 895 | } | 896 | } |
| 896 | 897 | ||
| @@ -927,6 +928,7 @@ void Image::CopyImageToBuffer(const VideoCommon::BufferImageCopy& copy, size_t b | |||
| 927 | break; | 928 | break; |
| 928 | default: | 929 | default: |
| 929 | ASSERT(false); | 930 | ASSERT(false); |
| 931 | break; | ||
| 930 | } | 932 | } |
| 931 | // Compressed formats don't have a pixel format or type | 933 | // Compressed formats don't have a pixel format or type |
| 932 | const bool is_compressed = gl_format == GL_NONE; | 934 | const bool is_compressed = gl_format == GL_NONE; |
diff --git a/src/video_core/renderer_opengl/renderer_opengl.cpp b/src/video_core/renderer_opengl/renderer_opengl.cpp index 8bd5eba7e..f29462f7c 100644 --- a/src/video_core/renderer_opengl/renderer_opengl.cpp +++ b/src/video_core/renderer_opengl/renderer_opengl.cpp | |||
| @@ -340,6 +340,7 @@ void RendererOpenGL::ConfigureFramebufferTexture(TextureInfo& texture, | |||
| 340 | texture.gl_type = GL_UNSIGNED_INT_8_8_8_8_REV; | 340 | texture.gl_type = GL_UNSIGNED_INT_8_8_8_8_REV; |
| 341 | // UNIMPLEMENTED_MSG("Unknown framebuffer pixel format: {}", | 341 | // UNIMPLEMENTED_MSG("Unknown framebuffer pixel format: {}", |
| 342 | // static_cast<u32>(framebuffer.pixel_format)); | 342 | // static_cast<u32>(framebuffer.pixel_format)); |
| 343 | break; | ||
| 343 | } | 344 | } |
| 344 | 345 | ||
| 345 | texture.resource.Release(); | 346 | texture.resource.Release(); |
diff --git a/src/video_core/renderer_vulkan/vk_scheduler.cpp b/src/video_core/renderer_vulkan/vk_scheduler.cpp index 7934f2a51..4a7b633b7 100644 --- a/src/video_core/renderer_vulkan/vk_scheduler.cpp +++ b/src/video_core/renderer_vulkan/vk_scheduler.cpp | |||
| @@ -221,6 +221,7 @@ void Scheduler::SubmitExecution(VkSemaphore signal_semaphore, VkSemaphore wait_s | |||
| 221 | [[fallthrough]]; | 221 | [[fallthrough]]; |
| 222 | default: | 222 | default: |
| 223 | vk::Check(result); | 223 | vk::Check(result); |
| 224 | break; | ||
| 224 | } | 225 | } |
| 225 | }); | 226 | }); |
| 226 | chunk->MarkSubmit(); | 227 | chunk->MarkSubmit(); |
diff --git a/src/video_core/renderer_vulkan/vk_texture_cache.cpp b/src/video_core/renderer_vulkan/vk_texture_cache.cpp index 853b80d8a..a65bbeb1c 100644 --- a/src/video_core/renderer_vulkan/vk_texture_cache.cpp +++ b/src/video_core/renderer_vulkan/vk_texture_cache.cpp | |||
| @@ -108,6 +108,7 @@ constexpr VkBorderColor ConvertBorderColor(const std::array<float, 4>& color) { | |||
| 108 | break; | 108 | break; |
| 109 | default: | 109 | default: |
| 110 | ASSERT_MSG(false, "Invalid surface type"); | 110 | ASSERT_MSG(false, "Invalid surface type"); |
| 111 | break; | ||
| 111 | } | 112 | } |
| 112 | } | 113 | } |
| 113 | if (info.storage) { | 114 | if (info.storage) { |
diff --git a/src/video_core/textures/decoders.cpp b/src/video_core/textures/decoders.cpp index fd1a4b987..59120cd09 100644 --- a/src/video_core/textures/decoders.cpp +++ b/src/video_core/textures/decoders.cpp | |||
| @@ -170,6 +170,7 @@ void Swizzle(std::span<u8> output, std::span<const u8> input, u32 bytes_per_pixe | |||
| 170 | #undef BPP_CASE | 170 | #undef BPP_CASE |
| 171 | default: | 171 | default: |
| 172 | ASSERT_MSG(false, "Invalid bytes_per_pixel={}", bytes_per_pixel); | 172 | ASSERT_MSG(false, "Invalid bytes_per_pixel={}", bytes_per_pixel); |
| 173 | break; | ||
| 173 | } | 174 | } |
| 174 | } | 175 | } |
| 175 | 176 | ||
| @@ -217,6 +218,7 @@ void SwizzleSubrect(std::span<u8> output, std::span<const u8> input, u32 bytes_p | |||
| 217 | #undef BPP_CASE | 218 | #undef BPP_CASE |
| 218 | default: | 219 | default: |
| 219 | ASSERT_MSG(false, "Invalid bytes_per_pixel={}", bytes_per_pixel); | 220 | ASSERT_MSG(false, "Invalid bytes_per_pixel={}", bytes_per_pixel); |
| 221 | break; | ||
| 220 | } | 222 | } |
| 221 | } | 223 | } |
| 222 | 224 | ||
| @@ -240,6 +242,7 @@ void UnswizzleSubrect(std::span<u8> output, std::span<const u8> input, u32 bytes | |||
| 240 | #undef BPP_CASE | 242 | #undef BPP_CASE |
| 241 | default: | 243 | default: |
| 242 | ASSERT_MSG(false, "Invalid bytes_per_pixel={}", bytes_per_pixel); | 244 | ASSERT_MSG(false, "Invalid bytes_per_pixel={}", bytes_per_pixel); |
| 245 | break; | ||
| 243 | } | 246 | } |
| 244 | } | 247 | } |
| 245 | 248 | ||