On Aug 21, 2010, at 1:54 PM, Steve Reinhardt wrote:
>
>>>>> It seems like the
>>>>> right answer in this case is to have the isa parser be able to figure out
>>>>> what registers need updating when an instruction is predicated false and
>>>>> do
>>>>> the update.
>
> My confusion is why we need the ISA parser to do that... why can't you
> just look at the destRegs field of the staticInst to figure this out?
The dyninst might be able to do something like this, I'm not completely sure.
The parser still needs to add the destination registers to the source registers
or a whole mechanism would have to be cerated in the O3 to do the wakeup logic
for for the predicate false case (which seems like a whole lot of trouble and
extra code):
void forwardOldRegs()
{
for (int idx = 0; idx < numDestRegs(); idx++) {
PhysRegIndex prev_phys_reg = prevDestRegIdx(idx);
TheISA::RegIndex original_dest_reg = staticInst->destRegIdx(idx);
if (original_dest_reg < TheISA::FP_Base_DepTag)
setIntRegOperand(staticInst, idx,
this->cpu->readIntReg(prev_phys_reg));
else if (original_dest_reg < TheISA::Ctrl_Base_DepTag)
setFloatRegOperandBits(staticInst, idx,
this->cpu->readFloatRegOperandBits(prev_phys_reg));
}
}
Ali
_______________________________________________
m5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/m5-dev