Moved some routine logs to higher verbosity levels.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@912 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
John Peterson 2008-10-18 20:34:06 +00:00
parent f71cc4e609
commit 1b76bd3863
18 changed files with 65 additions and 61 deletions

View File

@ -142,7 +142,7 @@ void CBoot::EmulatedBIOS(bool _bDebug)
u32 iLength = Memory::ReadUnchecked_U32(0x81300008); u32 iLength = Memory::ReadUnchecked_U32(0x81300008);
u32 iDVDOffset = Memory::ReadUnchecked_U32(0x8130000c); u32 iDVDOffset = Memory::ReadUnchecked_U32(0x8130000c);
LOG(MASTER_LOG, "DVDRead: offset: %08x memOffset: %08x length: %i", iDVDOffset, iRamAddress, iLength); LOG(MASTER_LOG + 200, "DVDRead: offset: %08x memOffset: %08x length: %i", iDVDOffset, iRamAddress, iLength);
DVDInterface::DVDRead(iDVDOffset, iRamAddress, iLength); DVDInterface::DVDRead(iDVDOffset, iRamAddress, iLength);
} while(PowerPC::ppcState.gpr[3] != 0x00); } while(PowerPC::ppcState.gpr[3] != 0x00);
@ -349,7 +349,7 @@ bool CBoot::EmulatedBIOS_Wii(bool _bDebug)
u32 iLength = Memory::ReadUnchecked_U32(0x81300008); u32 iLength = Memory::ReadUnchecked_U32(0x81300008);
u32 iDVDOffset = Memory::ReadUnchecked_U32(0x8130000c) << 2; u32 iDVDOffset = Memory::ReadUnchecked_U32(0x8130000c) << 2;
LOG(BOOT, "DVDRead: offset: %08x memOffse: %08x length: %i", iDVDOffset, iRamAddress, iLength); LOG(BOOT + 100, "DVDRead: offset: %08x memOffse: %08x length: %i", iDVDOffset, iRamAddress, iLength);
DVDInterface::DVDRead(iDVDOffset, iRamAddress, iLength); DVDInterface::DVDRead(iDVDOffset, iRamAddress, iLength);
} while(PowerPC::ppcState.gpr[3] != 0x00); } while(PowerPC::ppcState.gpr[3] != 0x00);

View File

@ -347,7 +347,7 @@ void LogPendingEvents()
void Idle() void Idle()
{ {
LOG(GEKKO, "Idle"); LOG(GEKKO + 300, "Idle");
idledCycles += downcount; idledCycles += downcount;
downcount = 0; downcount = 0;

View File

@ -124,7 +124,7 @@ void Read32(u32& _rReturnValue, const u32 _Address)
switch (_Address & 0xFFFF) switch (_Address & 0xFFFF)
{ {
case AI_CONTROL_REGISTER: //0x6C00 case AI_CONTROL_REGISTER: //0x6C00
LOG(AUDIO_INTERFACE, "AudioInterface(R) 0x%08x", _Address); LOG(AUDIO_INTERFACE + 100, "AudioInterface(R) 0x%08x", _Address);
_rReturnValue = g_AudioRegister.m_Control.hex; _rReturnValue = g_AudioRegister.m_Control.hex;
return; return;
@ -132,7 +132,7 @@ void Read32(u32& _rReturnValue, const u32 _Address)
// Sample Rate (AIGetDSPSampleRate) // Sample Rate (AIGetDSPSampleRate)
// 32bit state (highest bit PlayState) // AIGetStreamPlayState // 32bit state (highest bit PlayState) // AIGetStreamPlayState
case AI_VOLUME_REGISTER: //0x6C04 case AI_VOLUME_REGISTER: //0x6C04
LOG(AUDIO_INTERFACE, "AudioInterface(R) 0x%08x", _Address); LOG(AUDIO_INTERFACE + 100, "AudioInterface(R) 0x%08x", _Address);
_rReturnValue = g_AudioRegister.m_Volume.hex; _rReturnValue = g_AudioRegister.m_Volume.hex;
return; return;
@ -145,7 +145,7 @@ void Read32(u32& _rReturnValue, const u32 _Address)
case AI_INTERRUPT_TIMING: case AI_INTERRUPT_TIMING:
// When sample counter reaches the value of this register, the interrupt AIINT should // When sample counter reaches the value of this register, the interrupt AIINT should
// fire. // fire.
LOG(AUDIO_INTERFACE, "AudioInterface(R) 0x%08x", _Address); LOG(AUDIO_INTERFACE + 100, "AudioInterface(R) 0x%08x", _Address);
_rReturnValue = g_AudioRegister.m_InterruptTiming; _rReturnValue = g_AudioRegister.m_InterruptTiming;
return; return;
@ -200,7 +200,7 @@ void Write32(const u32 _Value, const u32 _Address)
// Sample Count Reset // Sample Count Reset
if (tmpAICtrl.SCRESET) if (tmpAICtrl.SCRESET)
{ {
LOG(AUDIO_INTERFACE, "Reset SampleCounter"); LOG(AUDIO_INTERFACE + 100, "Reset SampleCounter");
g_AudioRegister.m_SampleCounter = 0; g_AudioRegister.m_SampleCounter = 0;
g_AudioRegister.m_Control.SCRESET = 0; g_AudioRegister.m_Control.SCRESET = 0;
@ -217,7 +217,7 @@ void Write32(const u32 _Value, const u32 _Address)
case AI_VOLUME_REGISTER: case AI_VOLUME_REGISTER:
g_AudioRegister.m_Volume.hex = _Value; g_AudioRegister.m_Volume.hex = _Value;
LOG(AUDIO_INTERFACE, "Set m_Volume: left(%i) right(%i)", g_AudioRegister.m_Volume.leftVolume, g_AudioRegister.m_Volume.rightVolume); LOG(AUDIO_INTERFACE + 100, "Set m_Volume: left(%i) right(%i)", g_AudioRegister.m_Volume.leftVolume, g_AudioRegister.m_Volume.rightVolume);
break; break;
case AI_SAMPLE_COUNTER: case AI_SAMPLE_COUNTER:

View File

@ -171,7 +171,7 @@ void Shutdown()
void Read16(u16& _rReturnValue, const u32 _Address) void Read16(u16& _rReturnValue, const u32 _Address)
{ {
LOG(COMMANDPROCESSOR, "(r): 0x%08x", _Address); LOG(COMMANDPROCESSOR + 100, "(r): 0x%08x", _Address);
if (Core::g_CoreStartupParameter.bUseDualCore) if (Core::g_CoreStartupParameter.bUseDualCore)
{ {
//if ((_Address&0xFFF)>=0x20) //if ((_Address&0xFFF)>=0x20)
@ -258,7 +258,7 @@ bool AllowIdleSkipping()
void Write16(const u16 _Value, const u32 _Address) void Write16(const u16 _Value, const u32 _Address)
{ {
LOG(COMMANDPROCESSOR, "(w): 0x%04x @ 0x%08x",_Value,_Address); LOG(COMMANDPROCESSOR + 100, "(w): 0x%04x @ 0x%08x",_Value,_Address);
//Spin until queue is empty - it WILL become empty because this is the only thread //Spin until queue is empty - it WILL become empty because this is the only thread
//that submits data //that submits data
@ -275,7 +275,7 @@ void Write16(const u16 _Value, const u32 _Address)
while (fifo.bFF_GPReadEnable && fifo.CPReadWriteDistance > 0 && !(fifo.bFF_BPEnable && fifo.bFF_Breakpoint)) while (fifo.bFF_GPReadEnable && fifo.CPReadWriteDistance > 0 && !(fifo.bFF_BPEnable && fifo.bFF_Breakpoint))
//while (fifo.bFF_GPReadEnable && fifo.CPReadWriteDistance > fifo.CPHiWatermark && !(fifo.bFF_BPEnable && fifo.bFF_Breakpoint)) //while (fifo.bFF_GPReadEnable && fifo.CPReadWriteDistance > fifo.CPHiWatermark && !(fifo.bFF_BPEnable && fifo.bFF_Breakpoint))
ct++; ct++;
if (ct) {LOG(COMMANDPROCESSOR, "(Write16): %lu cycles for nothing :[ ", ct);} if (ct) {LOG(COMMANDPROCESSOR + 200, "(Write16): %lu cycles for nothing :[ ", ct);}
} }
#ifdef _WIN32 #ifdef _WIN32
//EnterCriticalSection(&fifo.sync); //EnterCriticalSection(&fifo.sync);

View File

@ -218,7 +218,7 @@ void Read16(u16& _uReturnValue, const u32 _iAddress)
if ((_iAddress & 0x6C00) != 0x6c00) if ((_iAddress & 0x6C00) != 0x6c00)
{ {
if (_iAddress != 0xCC005004) { if (_iAddress != 0xCC005004) {
LOG(DSPINTERFACE, "DSPInterface(r16) 0x%08x", _iAddress); LOG(DSPINTERFACE + 300, "DSPInterface(r16) 0x%08x", _iAddress);
} }
switch (_iAddress & 0xFFFF) switch (_iAddress & 0xFFFF)
@ -303,7 +303,7 @@ void Read16(u16& _uReturnValue, const u32 _iAddress)
void Write16(const u16 _Value, const u32 _Address) void Write16(const u16 _Value, const u32 _Address)
{ {
LOG(DSPINTERFACE, "DSPInterface(w16) 0x%04x 0x%08x", _Value, _Address); LOG(DSPINTERFACE + 300, "DSPInterface(w16) 0x%04x 0x%08x", _Value, _Address);
switch(_Address & 0xFFFF) switch(_Address & 0xFFFF)
{ {
@ -559,13 +559,13 @@ void Update_ARAM_DMA()
return; return;
g_arDMA.CntValid[0] = g_arDMA.CntValid[1] = false; g_arDMA.CntValid[0] = g_arDMA.CntValid[1] = false;
LOG(DSPINTERFACE,"ARAM DMA triggered"); LOG(DSPINTERFACE + 100,"ARAM DMA triggered");
//TODO: speedup //TODO: speedup
if (g_arDMA.Cnt.dir) if (g_arDMA.Cnt.dir)
{ {
//read from ARAM //read from ARAM
LOG(DSPINTERFACE,"ARAM DMA read %08x bytes from %08x to Mem: %08x",g_arDMA.Cnt.count, g_arDMA.ARAddr, g_arDMA.MMAddr); LOG(DSPINTERFACE + 100,"ARAM DMA read %08x bytes from %08x to Mem: %08x",g_arDMA.Cnt.count, g_arDMA.ARAddr, g_arDMA.MMAddr);
u32 iMemAddress = g_arDMA.MMAddr; u32 iMemAddress = g_arDMA.MMAddr;
u32 iARAMAddress = g_arDMA.ARAddr; u32 iARAMAddress = g_arDMA.ARAddr;
@ -585,7 +585,7 @@ void Update_ARAM_DMA()
u32 iARAMAddress = g_arDMA.ARAddr; u32 iARAMAddress = g_arDMA.ARAddr;
//write to g_ARAM //write to g_ARAM
LOG(DSPINTERFACE,"g_ARAM DMA write %08x bytes from %08x to Aram: %08x",g_arDMA.Cnt.count, g_arDMA.MMAddr, g_arDMA.ARAddr); LOG(DSPINTERFACE + 100,"g_ARAM DMA write %08x bytes from %08x to Aram: %08x",g_arDMA.Cnt.count, g_arDMA.MMAddr, g_arDMA.ARAddr);
for (u32 i = 0; i < g_arDMA.Cnt.count; i++) for (u32 i = 0; i < g_arDMA.Cnt.count; i++)
{ {
if (iARAMAddress < ARAM_SIZE) if (iARAMAddress < ARAM_SIZE)

View File

@ -279,7 +279,7 @@ bool DVDReadADPCM(u8* _pDestBuffer, u32 _iNumSamples)
void Read32(u32& _uReturnValue, const u32 _iAddress) void Read32(u32& _uReturnValue, const u32 _iAddress)
{ {
LOG(DVDINTERFACE, "DVD(r): 0x%08x", _iAddress); LOG(DVDINTERFACE + 300, "DVD(r): 0x%08x", _iAddress);
switch (_iAddress & 0xFFF) switch (_iAddress & 0xFFF)
{ {
@ -308,7 +308,7 @@ void Read32(u32& _uReturnValue, const u32 _iAddress)
void Write32(const u32 _iValue, const u32 _iAddress) void Write32(const u32 _iValue, const u32 _iAddress)
{ {
LOG(DVDINTERFACE, "DVD(w): 0x%08x @ 0x%08x", _iValue, _iAddress); LOG(DVDINTERFACE + 300, "DVD(w): 0x%08x @ 0x%08x", _iValue, _iAddress);
switch (_iAddress & 0x3FF) switch (_iAddress & 0x3FF)
{ {
@ -466,7 +466,7 @@ void ExecuteCommand(UDIDMAControlRegister& _DMAControlReg)
u32 iDVDOffset = dvdMem.Command[1] << 2; u32 iDVDOffset = dvdMem.Command[1] << 2;
u32 iSrcLength = dvdMem.Command[2]; u32 iSrcLength = dvdMem.Command[2];
if (false) { iSrcLength++; } // avoid warning << wtf is this? if (false) { iSrcLength++; } // avoid warning << wtf is this?
LOG(DVDINTERFACE, "DVD: Read ISO: DVDOffset=%08x, DMABuffer=%08x, SrcLength=%08x, DMALength=%08x",iDVDOffset,dvdMem.DMAAddress.Address,iSrcLength,dvdMem.DMALength.Length); LOG(DVDINTERFACE + 200, "DVD: Read ISO: DVDOffset=%08x, DMABuffer=%08x, SrcLength=%08x, DMALength=%08x",iDVDOffset,dvdMem.DMAAddress.Address,iSrcLength,dvdMem.DMALength.Length);
_dbg_assert_(DVDINTERFACE, iSrcLength == dvdMem.DMALength.Length); _dbg_assert_(DVDINTERFACE, iSrcLength == dvdMem.DMALength.Length);
if (DVDRead(iDVDOffset, dvdMem.DMAAddress.Address, dvdMem.DMALength.Length) != true) if (DVDRead(iDVDOffset, dvdMem.DMAAddress.Address, dvdMem.DMALength.Length) != true)

View File

@ -128,7 +128,7 @@ void CEXIChannel::Update()
void CEXIChannel::Read32(u32& _uReturnValue, const u32 _iRegister) void CEXIChannel::Read32(u32& _uReturnValue, const u32 _iRegister)
{ {
LOG(EXPANSIONINTERFACE, "ExtensionInterface(R): channel: %i reg: %i", m_ChannelId, _iRegister); LOG(EXPANSIONINTERFACE + 300, "ExtensionInterface(R): channel: %i reg: %i", m_ChannelId, _iRegister);
switch (_iRegister) switch (_iRegister)
{ {
@ -172,7 +172,7 @@ void CEXIChannel::Read32(u32& _uReturnValue, const u32 _iRegister)
void CEXIChannel::Write32(const u32 _iValue, const u32 _iRegister) void CEXIChannel::Write32(const u32 _iValue, const u32 _iRegister)
{ {
LOG(EXPANSIONINTERFACE, "ExtensionInterface(W): 0x%08x channel: %i reg: %i", _iValue, m_ChannelId, _iRegister); LOG(EXPANSIONINTERFACE + 200, "ExtensionInterface(W): 0x%08x channel: %i reg: %i", _iValue, m_ChannelId, _iRegister);
switch (_iRegister) switch (_iRegister)
{ {
@ -226,17 +226,17 @@ void CEXIChannel::Write32(const u32 _iValue, const u32 _iRegister)
break; break;
case EXI_DMAADDR: case EXI_DMAADDR:
LOG(EXPANSIONINTERFACE, "EXI: Wrote DMABuf, chan %i", m_ChannelId); LOG(EXPANSIONINTERFACE + 200, "EXI: Wrote DMABuf, chan %i", m_ChannelId);
m_DMAMemoryAddress = _iValue; m_DMAMemoryAddress = _iValue;
break; break;
case EXI_DMALENGTH: case EXI_DMALENGTH:
LOG(EXPANSIONINTERFACE, "EXI: Wrote DMASize, chan %i", m_ChannelId); LOG(EXPANSIONINTERFACE + 200, "EXI: Wrote DMASize, chan %i", m_ChannelId);
m_DMALength = _iValue; m_DMALength = _iValue;
break; break;
case EXI_DMACONTROL: case EXI_DMACONTROL:
LOG(EXPANSIONINTERFACE, "EXI: Wrote DMAControl, chan %i", m_ChannelId); LOG(EXPANSIONINTERFACE + 200, "EXI: Wrote DMAControl, chan %i", m_ChannelId);
m_Control.hex = _iValue; m_Control.hex = _iValue;
if (m_Control.TSTART) if (m_Control.TSTART)
@ -277,7 +277,7 @@ void CEXIChannel::Write32(const u32 _iValue, const u32 _iRegister)
break; break;
case EXI_IMMDATA: case EXI_IMMDATA:
LOG(EXPANSIONINTERFACE, "EXI: Wrote IMMData, chan %i", m_ChannelId); LOG(EXPANSIONINTERFACE + 200, "EXI: Wrote IMMData, chan %i", m_ChannelId);
m_ImmData = _iValue; m_ImmData = _iValue;
break; break;
} }

View File

@ -188,7 +188,7 @@ void CEXIIPL::TransferByte(u8& _uByte)
// debug only // debug only
else if ((m_uAddress & 0x60000000) == 0) else if ((m_uAddress & 0x60000000) == 0)
{ {
LOG(EXPANSIONINTERFACE, "EXI IPL-DEV: IPL access"); LOG(EXPANSIONINTERFACE + 200, "EXI IPL-DEV: IPL access");
} }
else if ((m_uAddress & 0x7FFFFF00) == 0x20000000) else if ((m_uAddress & 0x7FFFFF00) == 0x20000000)
{ {
@ -200,7 +200,7 @@ void CEXIIPL::TransferByte(u8& _uByte)
} }
else if ((m_uAddress & 0x7FFFFF00) == 0x20010000) else if ((m_uAddress & 0x7FFFFF00) == 0x20010000)
{ {
LOG(EXPANSIONINTERFACE, "EXI IPL-DEV: UART"); LOG(EXPANSIONINTERFACE + 300, "EXI IPL-DEV: UART");
} }
else else
{ {

View File

@ -252,12 +252,12 @@ bool CEXIMemoryCard::IsInterruptSet()
void CEXIMemoryCard::TransferByte(u8 &byte) void CEXIMemoryCard::TransferByte(u8 &byte)
{ {
LOG(EXPANSIONINTERFACE, "EXI MEMCARD: > %02x", byte); LOG(EXPANSIONINTERFACE + 300, "EXI MEMCARD: > %02x", byte);
if (m_uPosition == 0) if (m_uPosition == 0)
{ {
command = byte; // first byte is command command = byte; // first byte is command
byte = 0xFF; // would be tristate, but we don't care. byte = 0xFF; // would be tristate, but we don't care.
LOG(EXPANSIONINTERFACE, "EXI MEMCARD: command %02x", byte) LOG(EXPANSIONINTERFACE + 100, "EXI MEMCARD: command %02x", byte)
if(command == cmdClearStatus) if(command == cmdClearStatus)
{ {
@ -382,5 +382,5 @@ void CEXIMemoryCard::TransferByte(u8 &byte)
} }
} }
m_uPosition++; m_uPosition++;
LOG(EXPANSIONINTERFACE, "EXI MEMCARD: < %02x", byte); LOG(EXPANSIONINTERFACE + 300, "EXI MEMCARD: < %02x", byte);
} }

View File

@ -79,7 +79,7 @@ void CPeripheralInterface::Read32(u32& _uReturnValue, const u32 _iAddress)
return; return;
case PI_FIFO_WPTR: case PI_FIFO_WPTR:
LOG(PERIPHERALINTERFACE,"read writepointer, value = %08x",Fifo_CPUWritePointer); LOG(PERIPHERALINTERFACE + 300,"read writepointer, value = %08x",Fifo_CPUWritePointer);
_uReturnValue = Fifo_CPUWritePointer; //really writes in 32-byte chunks _uReturnValue = Fifo_CPUWritePointer; //really writes in 32-byte chunks
// Monk's gcube does some crazy align trickery here. // Monk's gcube does some crazy align trickery here.
@ -206,12 +206,12 @@ void CPeripheralInterface::SetInterrupt(InterruptCause _causemask, bool _bSet)
if (_bSet && !(m_InterruptCause & (u32)_causemask)) if (_bSet && !(m_InterruptCause & (u32)_causemask))
{ {
LOG(PERIPHERALINTERFACE,"Setting Interrupt %s (%s)",Debug_GetInterruptName(_causemask), "set"); LOG(PERIPHERALINTERFACE + 200,"Setting Interrupt %s (%s)",Debug_GetInterruptName(_causemask), "set");
} }
if (!_bSet && (m_InterruptCause & (u32)_causemask)) if (!_bSet && (m_InterruptCause & (u32)_causemask))
{ {
LOG(PERIPHERALINTERFACE,"Setting Interrupt %s (%s)",Debug_GetInterruptName(_causemask), "clear"); LOG(PERIPHERALINTERFACE + 200,"Setting Interrupt %s (%s)",Debug_GetInterruptName(_causemask), "clear");
} }
if (_bSet) if (_bSet)

View File

@ -87,7 +87,7 @@ void Init()
void Read16(u16& _uReturnValue, const u32 _iAddress) void Read16(u16& _uReturnValue, const u32 _iAddress)
{ {
LOG(PIXELENGINE, "(r16): 0x%08x", _iAddress); LOG(PIXELENGINE + 300, "(r16): 0x%08x", _iAddress);
switch (_iAddress & 0xFFF) switch (_iAddress & 0xFFF)
{ {
@ -109,12 +109,12 @@ void Read16(u16& _uReturnValue, const u32 _iAddress)
void Write32(const u32 _iValue, const u32 _iAddress) void Write32(const u32 _iValue, const u32 _iAddress)
{ {
LOG(PIXELENGINE, "(w32): 0x%08x @ 0x%08x",_iValue,_iAddress); LOG(PIXELENGINE + 200, "(w32): 0x%08x @ 0x%08x",_iValue,_iAddress);
} }
void Write16(const u16 _iValue, const u32 _iAddress) void Write16(const u16 _iValue, const u32 _iAddress)
{ {
LOG(PIXELENGINE, "(w16): 0x%04x @ 0x%08x",_iValue,_iAddress); LOG(PIXELENGINE + 300, "(w16): 0x%04x @ 0x%08x",_iValue,_iAddress);
switch(_iAddress & 0xFFF) switch(_iAddress & 0xFFF)
{ {
@ -169,7 +169,7 @@ void SetToken_OnMainThread(u64 userdata, int cyclesLate)
if (userdata >> 16) if (userdata >> 16)
g_bSignalTokenInterrupt = true; g_bSignalTokenInterrupt = true;
g_token = (u16)(userdata & 0xFFFF); g_token = (u16)(userdata & 0xFFFF);
LOG(PIXELENGINE, "VIDEO Plugin wrote token: %i", g_token); LOG(PIXELENGINE + 100, "VIDEO Plugin wrote token: %i", g_token);
UpdateInterrupts(); UpdateInterrupts();
} }
@ -193,7 +193,7 @@ void SetFinish()
{ {
CoreTiming::ScheduleEvent_Threadsafe( CoreTiming::ScheduleEvent_Threadsafe(
0, et_SetFinishOnMainThread); 0, et_SetFinishOnMainThread);
LOG(PIXELENGINE, "VIDEO Set Finish"); LOG(PIXELENGINE + 200, "VIDEO Set Finish");
} }
} // end of namespace PixelEngine } // end of namespace PixelEngine

View File

@ -268,7 +268,7 @@ void Shutdown()
void Read32(u32& _uReturnValue, const u32 _iAddress) void Read32(u32& _uReturnValue, const u32 _iAddress)
{ {
LOG(SERIALINTERFACE, "(r32): 0x%08x", _iAddress); LOG(SERIALINTERFACE + 300, "(r32): 0x%08x", _iAddress);
// SIBuffer // SIBuffer
if ((_iAddress >= 0xCC006480 && _iAddress < 0xCC006500) || if ((_iAddress >= 0xCC006480 && _iAddress < 0xCC006500) ||
@ -375,7 +375,7 @@ void Read32(u32& _uReturnValue, const u32 _iAddress)
void Write32(const u32 _iValue, const u32 _iAddress) void Write32(const u32 _iValue, const u32 _iAddress)
{ {
LOG(SERIALINTERFACE, "(w32): 0x%08x 0x%08x", _iValue,_iAddress); LOG(SERIALINTERFACE + 300, "(w32): 0x%08x 0x%08x", _iValue,_iAddress);
// SIBuffer // SIBuffer
if ((_iAddress >= 0xCC006480 && _iAddress < 0xCC006500) || if ((_iAddress >= 0xCC006480 && _iAddress < 0xCC006500) ||
@ -546,7 +546,7 @@ void RunSIBuffer()
int numOutput = int numOutput =
#endif #endif
g_Channel[g_ComCSR.CHANNEL].m_pDevice->RunBuffer(g_SIBuffer, inLength); g_Channel[g_ComCSR.CHANNEL].m_pDevice->RunBuffer(g_SIBuffer, inLength);
LOG(SERIALINTERFACE, "RunSIBuffer (intLen: %i outLen: %i) (processed: %i)", inLength, outLength, numOutput); LOG(SERIALINTERFACE + 200, "RunSIBuffer (intLen: %i outLen: %i) (processed: %i)", inLength, outLength, numOutput);
// Transfer completed // Transfer completed
GenerateSIInterrupt(INT_TCINT); GenerateSIInterrupt(INT_TCINT);

View File

@ -204,7 +204,7 @@ void Read16(u16& _uReturnValue, const u32 _iAddress)
return; return;
case VI_CONTROL_REGISTER: case VI_CONTROL_REGISTER:
LOG(VIDEOINTERFACE, "VideoInterface(r16): VI_CONTROL_REGISTER 0x%08x", m_VIDisplayControlRegister.Hex); LOG(VIDEOINTERFACE + 300, "VideoInterface(r16): VI_CONTROL_REGISTER 0x%08x", m_VIDisplayControlRegister.Hex);
_uReturnValue = m_VIDisplayControlRegister.Hex; _uReturnValue = m_VIDisplayControlRegister.Hex;
return; return;
@ -271,7 +271,7 @@ void Read16(u16& _uReturnValue, const u32 _iAddress)
void Write16(const u16 _iValue, const u32 _iAddress) void Write16(const u16 _iValue, const u32 _iAddress)
{ {
LOG(VIDEOINTERFACE, "(w16): 0x%04x, 0x%08x",_iValue,_iAddress); LOG(VIDEOINTERFACE + 300, "(w16): 0x%04x, 0x%08x",_iValue,_iAddress);
//Somewhere it sets screen width.. we need to communicate this to the gfx plugin... //Somewhere it sets screen width.. we need to communicate this to the gfx plugin...

View File

@ -38,17 +38,17 @@ void HWCALL Read32(u32& _rReturnValue, const u32 _Address)
{ {
case 0xc0: // __VISendI2CData case 0xc0: // __VISendI2CData
_rReturnValue = 0; _rReturnValue = 0;
LOG(WII_IOB, "IOP: Read32 from 0xc0 = 0x%08x (__VISendI2CData)", _rReturnValue); LOG(WII_IOB + 200, "IOP: Read32 from 0xc0 = 0x%08x (__VISendI2CData)", _rReturnValue);
break; break;
case 0xc4: // __VISendI2CData case 0xc4: // __VISendI2CData
_rReturnValue = 0; _rReturnValue = 0;
LOG(WII_IOB, "IOP: Read32 from 0xc4 = 0x%08x (__VISendI2CData)", _rReturnValue); LOG(WII_IOB + 200, "IOP: Read32 from 0xc4 = 0x%08x (__VISendI2CData)", _rReturnValue);
break; break;
case 0xc8: // __VISendI2CData case 0xc8: // __VISendI2CData
_rReturnValue = 0; _rReturnValue = 0;
LOG(WII_IOB, "IOP: Read32 from 0xc8 = 0x%08x (__VISendI2CData)", _rReturnValue); LOG(WII_IOB + 200, "IOP: Read32 from 0xc8 = 0x%08x (__VISendI2CData)", _rReturnValue);
break; break;
case 0x180: // __AIClockInit case 0x180: // __AIClockInit
@ -92,15 +92,15 @@ void HWCALL Write32(const u32 _Value, const u32 _Address)
switch(_Address & 0xFFFF) switch(_Address & 0xFFFF)
{ {
case 0xc0: // __VISendI2CData case 0xc0: // __VISendI2CData
LOG(WII_IOB, "IOP: Write32 to 0xc0 = 0x%08x (__VISendI2CData)", _Value); LOG(WII_IOB + 200, "IOP: Write32 to 0xc0 = 0x%08x (__VISendI2CData)", _Value);
break; break;
case 0xc4: // __VISendI2CData case 0xc4: // __VISendI2CData
LOG(WII_IOB, "IOP: Write32 to 0xc4 = 0x%08x (__VISendI2CData)", _Value); LOG(WII_IOB + 200, "IOP: Write32 to 0xc4 = 0x%08x (__VISendI2CData)", _Value);
break; break;
case 0xc8: // __VISendI2CData case 0xc8: // __VISendI2CData
LOG(WII_IOB, "IOP: Write32 to 0xc8 = 0x%08x (__VISendI2CData)", _Value); LOG(WII_IOB + 200, "IOP: Write32 to 0xc8 = 0x%08x (__VISendI2CData)", _Value);
break; break;
case 0x180: // __AIClockInit case 0x180: // __AIClockInit

View File

@ -129,7 +129,7 @@ void HWCALL Read32(u32& _rReturnValue, const u32 _Address)
_rReturnValue = g_IPC_Control.Hex; _rReturnValue = g_IPC_Control.Hex;
LOG(WII_IPC, "IOP: Read32 from IPC_CONTROL_REGISTER(0x04) = 0x%08x", _rReturnValue); LOG(WII_IPC + 200, "IOP: Read32 from IPC_CONTROL_REGISTER(0x04) = 0x%08x", _rReturnValue);
// CCPU::Break(); // CCPU::Break();
// if ((REASON_REG & 0x14) == 0x14) CALL IPCReplayHanlder // if ((REASON_REG & 0x14) == 0x14) CALL IPCReplayHanlder
@ -139,7 +139,7 @@ void HWCALL Read32(u32& _rReturnValue, const u32 _Address)
case IPC_REPLY_REGISTER: // looks a little bit like a callback function case IPC_REPLY_REGISTER: // looks a little bit like a callback function
_rReturnValue = g_Reply; _rReturnValue = g_Reply;
LOG(WII_IPC, "IOP: Write32 to IPC_REPLAY_REGISTER(0x08) = 0x%08x ", _rReturnValue); LOG(WII_IPC + 200, "IOP: Write32 to IPC_REPLAY_REGISTER(0x08) = 0x%08x ", _rReturnValue);
break; break;
case IPC_SENSOR_BAR_POWER_REGISTER: case IPC_SENSOR_BAR_POWER_REGISTER:
@ -160,13 +160,13 @@ void HWCALL Write32(const u32 _Value, const u32 _Address)
case IPC_COMMAND_REGISTER: // __ios_Ipc2 ... a value from __responses is loaded case IPC_COMMAND_REGISTER: // __ios_Ipc2 ... a value from __responses is loaded
{ {
g_Address = _Value; g_Address = _Value;
LOG(WII_IPC, "IOP: Write32 to IPC_ADDRESS_REGISTER(0x00) = 0x%08x", g_Address); LOG(WII_IPC + 100, "IOP: Write32 to IPC_ADDRESS_REGISTER(0x00) = 0x%08x", g_Address);
} }
break; break;
case IPC_CONTROL_REGISTER: case IPC_CONTROL_REGISTER:
{ {
LOG(WII_IPC, "IOP: Write32 to IPC_CONTROL_REGISTER(0x04) = 0x%08x (old: 0x%08x)", _Value, g_IPC_Control.Hex); LOG(WII_IPC + 100, "IOP: Write32 to IPC_CONTROL_REGISTER(0x04) = 0x%08x (old: 0x%08x)", _Value, g_IPC_Control.Hex);
UIPC_Control TempControl(_Value); UIPC_Control TempControl(_Value);
_dbg_assert_msg_(WII_IPC, TempControl.pad == 0, "IOP: Write to UIPC_Control.pad", _Address); _dbg_assert_msg_(WII_IPC, TempControl.pad == 0, "IOP: Write to UIPC_Control.pad", _Address);
@ -192,7 +192,7 @@ void HWCALL Write32(const u32 _Value, const u32 _Address)
UIPC_Status NewStatus(_Value); UIPC_Status NewStatus(_Value);
if (NewStatus.INTERRUPT) g_IPC_Status.INTERRUPT = 0; // clear interrupt if (NewStatus.INTERRUPT) g_IPC_Status.INTERRUPT = 0; // clear interrupt
LOG(WII_IPC, "IOP: Write32 to IPC_STATUS_REGISTER(0x30) = 0x%08x", _Value); LOG(WII_IPC + 100, "IOP: Write32 to IPC_STATUS_REGISTER(0x30) = 0x%08x", _Value);
} }
break; break;

View File

@ -350,7 +350,7 @@ void Update()
// check if we have to execute an acknowledged command // check if we have to execute an acknowledged command
if (!m_ReplyQueue.empty()) if (!m_ReplyQueue.empty())
{ {
LOG(WII_IPC_HLE, "-- Generate Reply %s (0x%08x)", m_ReplyQueue.front().second.c_str(), m_ReplyQueue.front().first); LOG(WII_IPC_HLE + 100, "-- Generate Reply %s (0x%08x)", m_ReplyQueue.front().second.c_str(), m_ReplyQueue.front().first);
WII_IPCInterface::GenerateReply(m_ReplyQueue.front().first); WII_IPCInterface::GenerateReply(m_ReplyQueue.front().first);
m_ReplyQueue.pop(); m_ReplyQueue.pop();
return; return;
@ -363,7 +363,7 @@ void Update()
u32 _Address = m_Ack.front(); u32 _Address = m_Ack.front();
m_Ack.pop(); m_Ack.pop();
ExecuteCommand(_Address); ExecuteCommand(_Address);
LOG(WII_IPC_HLE, "-- Generate Ack (0x%08x)", _Address); LOG(WII_IPC_HLE + 100, "-- Generate Ack (0x%08x)", _Address);
WII_IPCInterface::GenerateAck(_Address); WII_IPCInterface::GenerateAck(_Address);
} }
} }

View File

@ -228,6 +228,10 @@ void LogManager::Log(LogTypes::LOG_TYPE _type, const char *_fmt, ...)
m_Log[_type]->m_szShortName_, PC, Msg, eol); m_Log[_type]->m_szShortName_, PC, Msg, eol);
} }
// ==========================================================================================
// Level 0 verbosity logs will be written to all verbosity levels. Given that logging is enabled
// for that level. Level 1 verbosity will only be written to level 1, 2, 3 and so on.
// ---------------
int type = _type; int type = _type;
for (int i = LogManager::VERBOSITY_LEVELS; i >= vv ; i--) for (int i = LogManager::VERBOSITY_LEVELS; i >= vv ; i--)
{ {

View File

@ -201,7 +201,7 @@ void CheckExceptions()
SRR1 = MSR & 0x0780FF77; SRR1 = MSR & 0x0780FF77;
NPC = 0x80000800; NPC = 0x80000800;
LOG(GEKKO, "EXCEPTION_FPU_UNAVAILABLE"); LOG(GEKKO + 100, "EXCEPTION_FPU_UNAVAILABLE");
ppcState.Exceptions &= ~EXCEPTION_FPU_UNAVAILABLE; ppcState.Exceptions &= ~EXCEPTION_FPU_UNAVAILABLE;
SRR1 |= 0x02; //recoverable SRR1 |= 0x02; //recoverable
} }
@ -211,7 +211,7 @@ void CheckExceptions()
SRR1 = MSR & 0x0780FF77; SRR1 = MSR & 0x0780FF77;
NPC = 0x80000C00; NPC = 0x80000C00;
LOG(GEKKO, "EXCEPTION_SYSCALL (PC=%08x)",PC); LOG(GEKKO + 100, "EXCEPTION_SYSCALL (PC=%08x)",PC);
ppcState.Exceptions &= ~EXCEPTION_SYSCALL; ppcState.Exceptions &= ~EXCEPTION_SYSCALL;
SRR1 |= 0x02; //recoverable SRR1 |= 0x02; //recoverable
} }
@ -221,7 +221,7 @@ void CheckExceptions()
SRR1 = MSR & 0x0780FF77; SRR1 = MSR & 0x0780FF77;
NPC = 0x80000300; NPC = 0x80000300;
LOG(GEKKO, "EXCEPTION_DSI"); LOG(GEKKO + 100, "EXCEPTION_DSI");
ppcState.Exceptions &= ~EXCEPTION_DSI; ppcState.Exceptions &= ~EXCEPTION_DSI;
//SRR1 |= 0x02; //make recoverable ? //SRR1 |= 0x02; //make recoverable ?
} }
@ -259,7 +259,7 @@ void CheckExceptions()
NPC = 0x80000500; NPC = 0x80000500;
SRR1 = (MSR & 0x0780FF77); SRR1 = (MSR & 0x0780FF77);
LOG(GEKKO, "EXCEPTION_EXTERNAL_INT"); LOG(GEKKO + 100, "EXCEPTION_EXTERNAL_INT");
SRR1 |= 0x02; //set it to recoverable SRR1 |= 0x02; //set it to recoverable
_dbg_assert_msg_(GEKKO, (SRR1 & 0x02) != 0, "GEKKO", "EXTERNAL_INT unrecoverable???"); // unrecoverable exception !?! _dbg_assert_msg_(GEKKO, (SRR1 & 0x02) != 0, "GEKKO", "EXTERNAL_INT unrecoverable???"); // unrecoverable exception !?!
@ -272,7 +272,7 @@ void CheckExceptions()
ppcState.Exceptions &= ~EXCEPTION_DECREMENTER; ppcState.Exceptions &= ~EXCEPTION_DECREMENTER;
LOG(GEKKO, "EXCEPTION_DECREMENTER"); LOG(GEKKO + 100, "EXCEPTION_DECREMENTER");
SRR1 |= 0x02; //make recoverable SRR1 |= 0x02; //make recoverable
} }
else else