Pipelining Flashcards
Simple pipeline stages
Fetch, decode, execute, memory, writeback
In-order pipeline
when instructions go through the execute stage in program order
Data hazard
RAW, WAR, WAW. When two instructions are accessing the same value or address. Error caused by data dependencies.
Control hazard
when the execution of one instruction determines if another instruction is executed or not. (taken/not taken).
let’s say a program doesn’t run in sequential order of its instructions. Now what?
Dependency vs hazard
dependency is how two instructions are related, hazard is the problem or wrong execution that arises when two instructions are dependent.
Data stall vs propagated stall
data stall is when an instruction waits to enter a stage to avoid a data hazard. Propagated stall is when an instruction can’t fetch because the previous instruction has not executed yet.
Bypassing/Forwarding
forwarding data directly to the input port to the stage it is used. Like execution, memory or writeback.
Control Speculation
predict the result of a branch instruction. (taken/ not taken?)