mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
OpcodeDecoding: Don't raise panic alerts for unknown opcodes 0x01-0x07
A pop-up is no longer generated for the Wiggler capsule in Mario Party 5 (https://bugs.dolphin-emu.org/issues/8104).
This commit is contained in:
@ -193,13 +193,7 @@ public:
|
|||||||
}
|
}
|
||||||
OPCODE_CALLBACK(void OnUnknown(u8 opcode, const u8* data))
|
OPCODE_CALLBACK(void OnUnknown(u8 opcode, const u8* data))
|
||||||
{
|
{
|
||||||
if (static_cast<Opcode>(opcode) == Opcode::GX_UNKNOWN_RESET)
|
if (static_cast<Opcode>(opcode) == Opcode::GX_CMD_UNKNOWN_METRICS)
|
||||||
{
|
|
||||||
// Datel software uses this command
|
|
||||||
m_cycles += 6;
|
|
||||||
DEBUG_LOG_FMT(VIDEO, "GX Reset?");
|
|
||||||
}
|
|
||||||
else if (static_cast<Opcode>(opcode) == Opcode::GX_CMD_UNKNOWN_METRICS)
|
|
||||||
{
|
{
|
||||||
// 'Zelda Four Swords' calls it and checks the metrics registers after that
|
// 'Zelda Four Swords' calls it and checks the metrics registers after that
|
||||||
m_cycles += 6;
|
m_cycles += 6;
|
||||||
@ -213,11 +207,19 @@ public:
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (!s_is_fifo_error_seen)
|
// Datel software uses 0x01 during startup, and Mario Party 5's Wiggler capsule
|
||||||
|
// accidentally uses 0x01-0x03 due to sending 4 more vertices than intended.
|
||||||
|
// Hardware testing indicates that 0x01-0x07 do nothing, so to avoid annoying the user with
|
||||||
|
// spurious popups, we don't create a panic alert in those cases. Other unknown opcodes
|
||||||
|
// (such as 0x18) seem to result in hangs.
|
||||||
|
if (!s_is_fifo_error_seen && opcode > 0x07)
|
||||||
|
{
|
||||||
CommandProcessor::HandleUnknownOpcode(opcode, data, is_preprocess);
|
CommandProcessor::HandleUnknownOpcode(opcode, data, is_preprocess);
|
||||||
|
s_is_fifo_error_seen = true;
|
||||||
|
}
|
||||||
|
|
||||||
ERROR_LOG_FMT(VIDEO, "FIFO: Unknown Opcode({:#04x} @ {}, preprocessing = {})", opcode,
|
ERROR_LOG_FMT(VIDEO, "FIFO: Unknown Opcode({:#04x} @ {}, preprocessing = {})", opcode,
|
||||||
fmt::ptr(data), is_preprocess ? "yes" : "no");
|
fmt::ptr(data), is_preprocess ? "yes" : "no");
|
||||||
s_is_fifo_error_seen = true;
|
|
||||||
m_cycles += 1;
|
m_cycles += 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,6 @@ extern bool g_record_fifo_data;
|
|||||||
enum class Opcode
|
enum class Opcode
|
||||||
{
|
{
|
||||||
GX_NOP = 0x00,
|
GX_NOP = 0x00,
|
||||||
GX_UNKNOWN_RESET = 0x01,
|
|
||||||
|
|
||||||
GX_LOAD_BP_REG = 0x61,
|
GX_LOAD_BP_REG = 0x61,
|
||||||
GX_LOAD_CP_REG = 0x08,
|
GX_LOAD_CP_REG = 0x08,
|
||||||
|
Reference in New Issue
Block a user