Something like cpu->readIntReg(renamed_reg); 

Ali 

On Thu, 15 Sep
2011 14:44:59 -0400, Edward Kim  wrote:  

Hi

I want to look into the
register value when register is ready in rename stage.
What can I do for
it?
Specifically, I want to check the register value at line number 1022
in file src/cpu/o3/rename_impl.hh.
 Thanks,

Ed

file
src/cpu/o3/rename_impl.hh

 973 template 
 974 inline void
 975
DefaultRename::renameSrcRegs(DynInstPtr &inst, ThreadID tid)
 976 {
 977
assert(renameMap[tid] != 0);
 978
 979 unsigned num_src_regs =
inst->numSrcRegs();
 980
 981 // Get the architectual register numbers
from the source and
 982 // destination operands, and redirect them to
the right register.
 983 // Will need to mark dependencies though.
 984
for (int src_idx = 0; src_idx < num_src_regs; src_idx++) {
 985 RegIndex
src_reg = inst->srcRegIdx(src_idx);
 .......
 .......
 1006
inst->flattenSrcReg(src_idx, flat_src_reg);
 1007
 1008 // Look up the
source registers to get the phys. register they've
 1009 // been renamed
to, and set the sources to those registers.
 1010 PhysRegIndex
renamed_reg = renameMap[tid]->lookup(flat_src_reg);
 1011
 1012
DPRINTF(Rename, "[tid:%u]: Looking up arch reg %i, got "
 1013 "physical
reg %i.n", tid, (int)flat_src_reg,
 1014 (int)renamed_reg);
 1015
 1016
inst->renameSrcReg(src_idx, renamed_reg);
 1017
 1018 // See if the
register is ready or not.
 1019 if (scoreboard->getReg(renamed_reg) ==
true) {
 1020 DPRINTF(Rename, "[tid:%u]: Register %d is ready.n",
 1021
tid, renamed_reg);
 1022 /* ================== looking into the register
value here ================= */
 1023 inst->markSrcRegReady(src_idx);

1024 } else {
 1025 DPRINTF(Rename, "[tid:%u]: Register %d is not
ready.n",
 1026 tid, renamed_reg);
 1027 }

 
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Reply via email to