PIPELINING: forwarding

recall from last lecture, there were 2 NOPs inserted; however, when there is absolutely no forwarding, we must actually insert 3 NOPs (or have 3 stalls) since the instruction decode actually gates registers into the ALU and therefore the registers must exist:

however, generally, we can write the results from the destination register directly to the ALU:

(above as example from last day)

moreover, we could, in principle, write the results directly from "memory" (data cache) to the ALU, since the "memory" (data cache) read gives us the data as soon as the read is complete:

(above as final example from last day)

going further: better than this kind of forwarding