[JIT]: Fix compilation
This commit is contained in:
@@ -301,7 +301,7 @@ void Interpreter::Exec(const u32 instr) {
|
||||
lui(instr);
|
||||
break;
|
||||
case COP0:
|
||||
regs.cop0.decode(*this, instr);
|
||||
regs.cop0.decode(instr);
|
||||
break;
|
||||
case COP1:
|
||||
{
|
||||
|
||||
@@ -270,7 +270,7 @@ void JIT::Emit(const u32 instr) {
|
||||
lui(instr);
|
||||
break;
|
||||
case COP0:
|
||||
regs.cop0.decode(*this, instr);
|
||||
Util::panic("[JIT]: Unimplemented Cop0 decode");
|
||||
break;
|
||||
case COP1:
|
||||
{
|
||||
|
||||
@@ -451,18 +451,7 @@ ExceptionCode Cop0::GetTLBExceptionCode(const TLBError error, const TLBAccessTyp
|
||||
}
|
||||
}
|
||||
|
||||
template <class T>
|
||||
void Cop0::decode(T &cpu, u32 instr) {
|
||||
if constexpr (std::is_same_v<decltype(cpu), Interpreter &>) {
|
||||
decodeInterp(instr);
|
||||
} else {
|
||||
Util::panic("What the fuck did you just give me?!!");
|
||||
}
|
||||
}
|
||||
|
||||
template void Cop0::decode<Interpreter>(Interpreter &, u32);
|
||||
|
||||
void Cop0::decodeInterp(const u32 instr) {
|
||||
void Cop0::decode(const u32 instr) {
|
||||
const u8 mask_cop = instr >> 21 & 0x1F;
|
||||
const u8 mask_cop2 = instr & 0x3F;
|
||||
switch (mask_cop) {
|
||||
|
||||
@@ -229,8 +229,7 @@ struct Cop0 {
|
||||
TLBEntry tlb[32]{};
|
||||
TLBError tlbError = NONE;
|
||||
s64 openbus{};
|
||||
template <class T>
|
||||
void decode(T &, u32);
|
||||
|
||||
[[nodiscard]] FORCE_INLINE u32 GetRandom() const {
|
||||
u32 val = rand();
|
||||
const auto wired_ = GetWired();
|
||||
@@ -270,13 +269,13 @@ struct Cop0 {
|
||||
TLBEntry *TLBTryMatch(u64 vaddr) const;
|
||||
void HandleTLBException(u64 vaddr) const;
|
||||
static ExceptionCode GetTLBExceptionCode(TLBError error, TLBAccessType accessType);
|
||||
void decode(u32);
|
||||
|
||||
private:
|
||||
Registers ®s;
|
||||
[[nodiscard]] FORCE_INLINE u32 GetWired() const { return wired & 0x3F; }
|
||||
[[nodiscard]] FORCE_INLINE u32 GetCount() const { return u32(u64(count >> 1)); }
|
||||
|
||||
void decodeInterp(u32);
|
||||
void mtc0(u32);
|
||||
void dmtc0(u32);
|
||||
void mfc0(u32);
|
||||
|
||||
Reference in New Issue
Block a user