SPARC: Add a traceflag for register windows.
This commit is contained in:
parent
7aa875f4f3
commit
88ee7d4c32
3 changed files with 6 additions and 5 deletions
|
@ -45,6 +45,7 @@ if env['TARGET_ISA'] == 'sparc':
|
|||
|
||||
SimObject('SparcTLB.py')
|
||||
TraceFlag('Sparc', "Generic SPARC ISA stuff")
|
||||
TraceFlag('RegisterWindows', "Register window manipulation")
|
||||
|
||||
if env['FULL_SYSTEM']:
|
||||
SimObject('SparcSystem.py')
|
||||
|
|
|
@ -55,7 +55,7 @@ int IntRegFile::flattenIndex(int reg)
|
|||
{
|
||||
int flatIndex = offset[reg >> FrameOffsetBits]
|
||||
| (reg & FrameOffsetMask);
|
||||
DPRINTF(Sparc, "Flattened index %d into %d.\n", reg, flatIndex);
|
||||
DPRINTF(RegisterWindows, "Flattened index %d into %d.\n", reg, flatIndex);
|
||||
return flatIndex;
|
||||
}
|
||||
|
||||
|
@ -135,12 +135,12 @@ void IntRegFile::setCWP(int cwp)
|
|||
regView[Locals] = regSegments[index+1];
|
||||
regView[Inputs] = regSegments[(index+2) % (NWindows * 2)];
|
||||
|
||||
DPRINTF(Sparc, "Changed the CWP value to %d\n", cwp);
|
||||
DPRINTF(RegisterWindows, "Changed the CWP value to %d\n", cwp);
|
||||
}
|
||||
|
||||
void IntRegFile::setGlobals(int gl)
|
||||
{
|
||||
DPRINTF(Sparc, "Now using %d globals\n", gl);
|
||||
DPRINTF(RegisterWindows, "Now using %d globals\n", gl);
|
||||
|
||||
regView[Globals] = regGlobals[gl];
|
||||
offset[Globals] = RegGlobalOffset + gl * RegsPerFrame;
|
||||
|
|
|
@ -155,7 +155,7 @@ int SparcISA::flattenIntIndex(ThreadContext * tc, int reg)
|
|||
{
|
||||
int gl = tc->readMiscRegNoEffect(MISCREG_GL);
|
||||
int cwp = tc->readMiscRegNoEffect(MISCREG_CWP);
|
||||
//DPRINTF(Sparc, "Global Level = %d, Current Window Pointer = %d\n", gl, cwp);
|
||||
//DPRINTF(RegisterWindows, "Global Level = %d, Current Window Pointer = %d\n", gl, cwp);
|
||||
int newReg;
|
||||
//The total number of global registers
|
||||
int numGlobals = (MaxGL + 1) * 8;
|
||||
|
@ -214,7 +214,7 @@ int SparcISA::flattenIntIndex(ThreadContext * tc, int reg)
|
|||
}
|
||||
else
|
||||
panic("Tried to flatten invalid register index %d!\n", reg);
|
||||
DPRINTF(Sparc, "Flattened register %d to %d.\n", reg, newReg);
|
||||
DPRINTF(RegisterWindows, "Flattened register %d to %d.\n", reg, newReg);
|
||||
return newReg;
|
||||
//return intRegFile.flattenIndex(reg);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue