Lecture-11 Dynamic Scheduling A
Lecture-11 Dynamic Scheduling A
1
Summary of contents covered
• Introduction to RISC-V processor
• Assembly and Machine language of RISC-V
• RISC-V Single Cycle Implementation
• Pipelining concepts and Hazards
• Pipelined RISC-V Implementation
• Cache memory design
2
Forwarding and stalls in Pipeline
• In pipelined processor, in case of data hazards, pipelined
is stalled if data dependence is not resolved by bypass.
4
Benefits of Dynamic scheduling
5
Benefits of Dynamic scheduling
6
Instruction Level Parallelism
(Dynamic Scheduling & Tomasulo Algorithm)
Advantages of Dynamic Scheduling
• Dynamic scheduling - hardware rearranges the
instruction execution to reduce stalls while maintaining
data flow and exception behavior
• Handles cases when dependences unknown at compile
time
– it allows the processor to tolerate unpredictable
delays such as cache misses, by executing other
code while waiting for the miss to resolve
• Allows code that compiled for one pipeline to run
efficiently on a different pipeline
• Simplifies the compiler
• Leads to hardware speculation, a technique with
significant performance advantages (discuss later)
Add1
Add2 Mult1
Add3 Mult2
Reservation To Mem
Stations
FP
FP adders
adders FP
FP multipliers
multipliers
In addition
• Register result status table—Indicates which
functional unit will write each register, if one exists.
Blank when no pending instructions that will write that
register.
CMSC 411 - 10 (from Patterson) 15
Three Stages of Tomasulo
Algorithm
1. Issue—get instruction from FP Op Queue
– If reservation station free (no structural hazard),
control issues instr & sends operands (renames
registers).
2. Execute—operate on operands (EX)
– When both operands ready then execute;
if not ready, watch Common Data Bus for result
3. Write result—finish execution (WB)
– Write on Common Data Bus to all awaiting units;
Clock cycle
counter