summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/core/arm/dynarmic/arm_dynarmic.cpp2
-rw-r--r--src/core/arm/dyncom/arm_dyncom_interpreter.cpp8
-rw-r--r--src/core/arm/skyeye_common/armstate.h2
-rw-r--r--src/core/file_sys/archive_backend.cpp2
-rw-r--r--src/core/hle/applets/erreula.cpp4
-rw-r--r--src/core/hle/applets/mii_selector.cpp4
-rw-r--r--src/core/hle/applets/mint.cpp4
-rw-r--r--src/core/hle/applets/swkbd.cpp4
-rw-r--r--src/core/hle/kernel/kernel.h3
-rw-r--r--src/core/hw/gpu.cpp2
-rw-r--r--src/core/hw/gpu.h4
11 files changed, 22 insertions, 17 deletions
diff --git a/src/core/arm/dynarmic/arm_dynarmic.cpp b/src/core/arm/dynarmic/arm_dynarmic.cpp
index 7d2790b08..0a0b91590 100644
--- a/src/core/arm/dynarmic/arm_dynarmic.cpp
+++ b/src/core/arm/dynarmic/arm_dynarmic.cpp
@@ -136,7 +136,7 @@ MICROPROFILE_DEFINE(ARM_Jit, "ARM JIT", "ARM JIT", MP_RGB(255, 64, 64));
136void ARM_Dynarmic::ExecuteInstructions(int num_instructions) { 136void ARM_Dynarmic::ExecuteInstructions(int num_instructions) {
137 MICROPROFILE_SCOPE(ARM_Jit); 137 MICROPROFILE_SCOPE(ARM_Jit);
138 138
139 unsigned ticks_executed = jit->Run(static_cast<unsigned>(num_instructions)); 139 std::size_t ticks_executed = jit->Run(static_cast<unsigned>(num_instructions));
140 140
141 AddTicks(ticks_executed); 141 AddTicks(ticks_executed);
142} 142}
diff --git a/src/core/arm/dyncom/arm_dyncom_interpreter.cpp b/src/core/arm/dyncom/arm_dyncom_interpreter.cpp
index f4fbb8d04..3522d1e82 100644
--- a/src/core/arm/dyncom/arm_dyncom_interpreter.cpp
+++ b/src/core/arm/dyncom/arm_dyncom_interpreter.cpp
@@ -759,7 +759,7 @@ static ThumbDecodeStatus DecodeThumbInstruction(u32 inst, u32 addr, u32* arm_ins
759 ThumbDecodeStatus ret = TranslateThumbInstruction(addr, inst, arm_inst, inst_size); 759 ThumbDecodeStatus ret = TranslateThumbInstruction(addr, inst, arm_inst, inst_size);
760 if (ret == ThumbDecodeStatus::BRANCH) { 760 if (ret == ThumbDecodeStatus::BRANCH) {
761 int inst_index; 761 int inst_index;
762 int table_length = arm_instruction_trans_len; 762 int table_length = static_cast<int>(arm_instruction_trans_len);
763 u32 tinstr = GetThumbInstruction(inst, addr); 763 u32 tinstr = GetThumbInstruction(inst, addr);
764 764
765 switch ((tinstr & 0xF800) >> 11) { 765 switch ((tinstr & 0xF800) >> 11) {
@@ -838,7 +838,7 @@ static unsigned int InterpreterTranslateInstruction(const ARMul_State* cpu, cons
838 return inst_size; 838 return inst_size;
839} 839}
840 840
841static int InterpreterTranslateBlock(ARMul_State* cpu, int& bb_start, u32 addr) { 841static int InterpreterTranslateBlock(ARMul_State* cpu, std::size_t& bb_start, u32 addr) {
842 MICROPROFILE_SCOPE(DynCom_Decode); 842 MICROPROFILE_SCOPE(DynCom_Decode);
843 843
844 // Decode instruction, get index 844 // Decode instruction, get index
@@ -871,7 +871,7 @@ static int InterpreterTranslateBlock(ARMul_State* cpu, int& bb_start, u32 addr)
871 return KEEP_GOING; 871 return KEEP_GOING;
872} 872}
873 873
874static int InterpreterTranslateSingle(ARMul_State* cpu, int& bb_start, u32 addr) { 874static int InterpreterTranslateSingle(ARMul_State* cpu, std::size_t& bb_start, u32 addr) {
875 MICROPROFILE_SCOPE(DynCom_Decode); 875 MICROPROFILE_SCOPE(DynCom_Decode);
876 876
877 ARM_INST_PTR inst_base = nullptr; 877 ARM_INST_PTR inst_base = nullptr;
@@ -1620,7 +1620,7 @@ unsigned InterpreterMainLoop(ARMul_State* cpu) {
1620 unsigned int addr; 1620 unsigned int addr;
1621 unsigned int num_instrs = 0; 1621 unsigned int num_instrs = 0;
1622 1622
1623 int ptr; 1623 std::size_t ptr;
1624 1624
1625 LOAD_NZCVT; 1625 LOAD_NZCVT;
1626DISPATCH : { 1626DISPATCH : {
diff --git a/src/core/arm/skyeye_common/armstate.h b/src/core/arm/skyeye_common/armstate.h
index 1a707ff7e..893877797 100644
--- a/src/core/arm/skyeye_common/armstate.h
+++ b/src/core/arm/skyeye_common/armstate.h
@@ -230,7 +230,7 @@ public:
230 230
231 // TODO(bunnei): Move this cache to a better place - it should be per codeset (likely per 231 // TODO(bunnei): Move this cache to a better place - it should be per codeset (likely per
232 // process for our purposes), not per ARMul_State (which tracks CPU core state). 232 // process for our purposes), not per ARMul_State (which tracks CPU core state).
233 std::unordered_map<u32, int> instruction_cache; 233 std::unordered_map<u32, std::size_t> instruction_cache;
234 234
235private: 235private:
236 void ResetMPCoreCP15Registers(); 236 void ResetMPCoreCP15Registers();
diff --git a/src/core/file_sys/archive_backend.cpp b/src/core/file_sys/archive_backend.cpp
index 1fae0ede0..87a240d7a 100644
--- a/src/core/file_sys/archive_backend.cpp
+++ b/src/core/file_sys/archive_backend.cpp
@@ -90,6 +90,8 @@ std::u16string Path::AsU16Str() const {
90 LOG_ERROR(Service_FS, "LowPathType cannot be converted to u16string!"); 90 LOG_ERROR(Service_FS, "LowPathType cannot be converted to u16string!");
91 return {}; 91 return {};
92 } 92 }
93
94 UNREACHABLE();
93} 95}
94 96
95std::vector<u8> Path::AsBinary() const { 97std::vector<u8> Path::AsBinary() const {
diff --git a/src/core/hle/applets/erreula.cpp b/src/core/hle/applets/erreula.cpp
index 75d7fd9fc..518f371f5 100644
--- a/src/core/hle/applets/erreula.cpp
+++ b/src/core/hle/applets/erreula.cpp
@@ -31,8 +31,8 @@ ResultCode ErrEula::ReceiveParameter(const Service::APT::MessageParameter& param
31 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size); 31 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size);
32 // Create a SharedMemory that directly points to this heap block. 32 // Create a SharedMemory that directly points to this heap block.
33 framebuffer_memory = Kernel::SharedMemory::CreateForApplet( 33 framebuffer_memory = Kernel::SharedMemory::CreateForApplet(
34 heap_memory, 0, heap_memory->size(), MemoryPermission::ReadWrite, 34 heap_memory, 0, capture_info.size, MemoryPermission::ReadWrite, MemoryPermission::ReadWrite,
35 MemoryPermission::ReadWrite, "ErrEula Memory"); 35 "ErrEula Memory");
36 36
37 // Send the response message with the newly created SharedMemory 37 // Send the response message with the newly created SharedMemory
38 Service::APT::MessageParameter result; 38 Service::APT::MessageParameter result;
diff --git a/src/core/hle/applets/mii_selector.cpp b/src/core/hle/applets/mii_selector.cpp
index 89f08daa2..705859f1e 100644
--- a/src/core/hle/applets/mii_selector.cpp
+++ b/src/core/hle/applets/mii_selector.cpp
@@ -38,8 +38,8 @@ ResultCode MiiSelector::ReceiveParameter(const Service::APT::MessageParameter& p
38 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size); 38 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size);
39 // Create a SharedMemory that directly points to this heap block. 39 // Create a SharedMemory that directly points to this heap block.
40 framebuffer_memory = Kernel::SharedMemory::CreateForApplet( 40 framebuffer_memory = Kernel::SharedMemory::CreateForApplet(
41 heap_memory, 0, heap_memory->size(), MemoryPermission::ReadWrite, 41 heap_memory, 0, capture_info.size, MemoryPermission::ReadWrite, MemoryPermission::ReadWrite,
42 MemoryPermission::ReadWrite, "MiiSelector Memory"); 42 "MiiSelector Memory");
43 43
44 // Send the response message with the newly created SharedMemory 44 // Send the response message with the newly created SharedMemory
45 Service::APT::MessageParameter result; 45 Service::APT::MessageParameter result;
diff --git a/src/core/hle/applets/mint.cpp b/src/core/hle/applets/mint.cpp
index 31a79ea17..50d79190b 100644
--- a/src/core/hle/applets/mint.cpp
+++ b/src/core/hle/applets/mint.cpp
@@ -31,8 +31,8 @@ ResultCode Mint::ReceiveParameter(const Service::APT::MessageParameter& paramete
31 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size); 31 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size);
32 // Create a SharedMemory that directly points to this heap block. 32 // Create a SharedMemory that directly points to this heap block.
33 framebuffer_memory = Kernel::SharedMemory::CreateForApplet( 33 framebuffer_memory = Kernel::SharedMemory::CreateForApplet(
34 heap_memory, 0, heap_memory->size(), MemoryPermission::ReadWrite, 34 heap_memory, 0, capture_info.size, MemoryPermission::ReadWrite, MemoryPermission::ReadWrite,
35 MemoryPermission::ReadWrite, "Mint Memory"); 35 "Mint Memory");
36 36
37 // Send the response message with the newly created SharedMemory 37 // Send the response message with the newly created SharedMemory
38 Service::APT::MessageParameter result; 38 Service::APT::MessageParameter result;
diff --git a/src/core/hle/applets/swkbd.cpp b/src/core/hle/applets/swkbd.cpp
index fdf8807b0..0bc471a3a 100644
--- a/src/core/hle/applets/swkbd.cpp
+++ b/src/core/hle/applets/swkbd.cpp
@@ -41,8 +41,8 @@ ResultCode SoftwareKeyboard::ReceiveParameter(Service::APT::MessageParameter con
41 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size); 41 heap_memory = std::make_shared<std::vector<u8>>(capture_info.size);
42 // Create a SharedMemory that directly points to this heap block. 42 // Create a SharedMemory that directly points to this heap block.
43 framebuffer_memory = Kernel::SharedMemory::CreateForApplet( 43 framebuffer_memory = Kernel::SharedMemory::CreateForApplet(
44 heap_memory, 0, heap_memory->size(), MemoryPermission::ReadWrite, 44 heap_memory, 0, capture_info.size, MemoryPermission::ReadWrite, MemoryPermission::ReadWrite,
45 MemoryPermission::ReadWrite, "SoftwareKeyboard Memory"); 45 "SoftwareKeyboard Memory");
46 46
47 // Send the response message with the newly created SharedMemory 47 // Send the response message with the newly created SharedMemory
48 Service::APT::MessageParameter result; 48 Service::APT::MessageParameter result;
diff --git a/src/core/hle/kernel/kernel.h b/src/core/hle/kernel/kernel.h
index 9cf288b08..142bb84b2 100644
--- a/src/core/hle/kernel/kernel.h
+++ b/src/core/hle/kernel/kernel.h
@@ -8,6 +8,7 @@
8#include <string> 8#include <string>
9#include <utility> 9#include <utility>
10#include <boost/smart_ptr/intrusive_ptr.hpp> 10#include <boost/smart_ptr/intrusive_ptr.hpp>
11#include "common/assert.h"
11#include "common/common_types.h" 12#include "common/common_types.h"
12 13
13namespace Kernel { 14namespace Kernel {
@@ -84,6 +85,8 @@ public:
84 case HandleType::ClientSession: 85 case HandleType::ClientSession:
85 return false; 86 return false;
86 } 87 }
88
89 UNREACHABLE();
87 } 90 }
88 91
89public: 92public:
diff --git a/src/core/hw/gpu.cpp b/src/core/hw/gpu.cpp
index 6838e449c..83ad9d898 100644
--- a/src/core/hw/gpu.cpp
+++ b/src/core/hw/gpu.cpp
@@ -29,7 +29,7 @@ namespace GPU {
29Regs g_regs; 29Regs g_regs;
30 30
31/// 268MHz CPU clocks / 60Hz frames per second 31/// 268MHz CPU clocks / 60Hz frames per second
32const u64 frame_ticks = BASE_CLOCK_RATE_ARM11 / SCREEN_REFRESH_RATE; 32const u64 frame_ticks = static_cast<u64>(BASE_CLOCK_RATE_ARM11 / SCREEN_REFRESH_RATE);
33/// Event id for CoreTiming 33/// Event id for CoreTiming
34static int vblank_event; 34static int vblank_event;
35 35
diff --git a/src/core/hw/gpu.h b/src/core/hw/gpu.h
index 21b127fee..e3d0a0e08 100644
--- a/src/core/hw/gpu.h
+++ b/src/core/hw/gpu.h
@@ -74,9 +74,9 @@ struct Regs {
74 case PixelFormat::RGB5A1: 74 case PixelFormat::RGB5A1:
75 case PixelFormat::RGBA4: 75 case PixelFormat::RGBA4:
76 return 2; 76 return 2;
77 default:
78 UNIMPLEMENTED();
79 } 77 }
78
79 UNREACHABLE();
80 } 80 }
81 81
82 INSERT_PADDING_WORDS(0x4); 82 INSERT_PADDING_WORDS(0x4);