Core: Convert logging over to fmt pt.2

Continues the core migration of logs up to the EXI handling code.
This commit is contained in:
Lioncash
2020-11-19 21:45:54 -05:00
parent 858d7612ef
commit a0f9b041a0
48 changed files with 504 additions and 488 deletions

View File

@ -19,7 +19,7 @@ namespace DSP::LLE
{
void DSPPatches::Patch(std::size_t index)
{
PanicAlert("Patch functionality not supported in DSP module.");
PanicAlertFmt("Patch functionality not supported in DSP module.");
}
DSPDebugInterface::DSPDebugInterface() = default;
@ -252,12 +252,12 @@ bool DSPDebugInterface::IsMemCheck(u32 address, size_t size) const
void DSPDebugInterface::ClearAllMemChecks()
{
PanicAlert("MemCheck functionality not supported in DSP module.");
PanicAlertFmt("MemCheck functionality not supported in DSP module.");
}
void DSPDebugInterface::ToggleMemCheck(u32 address, bool read, bool write, bool log)
{
PanicAlert("MemCheck functionality not supported in DSP module.");
PanicAlertFmt("MemCheck functionality not supported in DSP module.");
}
// =======================================================

View File

@ -81,7 +81,7 @@ void CodeLoaded(const u8* ptr, size_t size)
DSP::DumpDSPCode(ptr, size, g_dsp.iram_crc);
}
NOTICE_LOG(DSPLLE, "g_dsp.iram_crc: %08x", g_dsp.iram_crc);
NOTICE_LOG_FMT(DSPLLE, "g_dsp.iram_crc: {:08x}", g_dsp.iram_crc);
Symbols::Clear();
Symbols::AutoDisassembly(0x0, 0x1000);

View File

@ -129,8 +129,8 @@ static bool LoadDSPRom(u16* rom, const std::string& filename, u32 size_in_bytes)
if (bytes.size() != size_in_bytes)
{
ERROR_LOG(DSPLLE, "%s has a wrong size (%zu, expected %u)", filename.c_str(), bytes.size(),
size_in_bytes);
ERROR_LOG_FMT(DSPLLE, "{} has a wrong size ({}, expected {})", filename, bytes.size(),
size_in_bytes);
return false;
}
@ -264,7 +264,7 @@ void DSPLLE::DSP_WriteMailBoxHigh(bool cpu_mailbox, u16 value)
if (gdsp_mbox_peek(MAILBOX_CPU) & 0x80000000)
{
// the DSP didn't read the previous value
WARN_LOG(DSPLLE, "Mailbox isn't empty ... strange");
WARN_LOG_FMT(DSPLLE, "Mailbox isn't empty ... strange");
}
#if PROFILE
@ -278,7 +278,7 @@ void DSPLLE::DSP_WriteMailBoxHigh(bool cpu_mailbox, u16 value)
}
else
{
ERROR_LOG(DSPLLE, "CPU can't write to DSP mailbox");
ERROR_LOG_FMT(DSPLLE, "CPU can't write to DSP mailbox");
}
}
@ -290,7 +290,7 @@ void DSPLLE::DSP_WriteMailBoxLow(bool cpu_mailbox, u16 value)
}
else
{
ERROR_LOG(DSPLLE, "CPU can't write to DSP mailbox");
ERROR_LOG_FMT(DSPLLE, "CPU can't write to DSP mailbox");
}
}

View File

@ -86,11 +86,10 @@ void AutoDisassembly(u16 start_addr, u16 end_addr)
std::string buf;
if (!disasm.DisassembleOpcode(ptr, &addr, buf))
{
ERROR_LOG(DSPLLE, "disasm failed at %04x", addr);
ERROR_LOG_FMT(DSPLLE, "disasm failed at {:04x}", addr);
break;
}
// NOTICE_LOG(DSPLLE, "Added %04x %i %s", addr, line_counter, buf.c_str());
lines.push_back(buf);
line_counter++;
}