Академический Документы
Профессиональный Документы
Культура Документы
contnd
The above diagram shows the dependence of
each instruction with respect to the first
instruction SUB and the result stored in $2
register.
As above, the and & or instructions would
get the incorrect value 10(assumed value of $2
before execution of SUB instruction).
Instructions that would get the correct value of
20 are add & sw (since both the instruction
will need the value from / after CC5(clock
cycle).
When the result is available in CC3, and the above condition is TRUE
then the hazard is detected and forwarding process must be initiated
to the next instruction, at the end of EX stage (CC3) of the current
instruction. Here in this example condition 1a is TRUE.
1a. EX/MEM.RegisterRd = ID/EX.RegisterRs = $2 is TRUE.