Dynamic Scheduling Using Tomasulo's Approach
Dynamic Scheduling Using Tomasulo's Approach
Explain the Tomasulos approach used in dynamic scheduling for overcoming data hazards.
Or
Briefly explain how to overcome data hazards with dynamic scheduling using Tomasulos approach
Or
What is dynamic scheduling? Explain how it is used to reduce data hazards
Or
Explain the function of Tomasulos approach
Dynamic Scheduling
The Dynamic Scheduling is a technique in which the hardware rearranges the
instruction execution to reduce the stalls while maintaining data flow and exception
behaviour.
Advantages
It enables handling some cases when dependences are unknown at compile time
It simplifies the compiler
It allows code that was compiled with one pipeline in mind to run efficiently on a
different pipeline
Uses speculation technique to improve performance
Overcoming Data Hazards with Dynamic Scheduling:
Although a dynamically scheduled processor cannot change the data flow, it tries to
avoid stalling when dependences, which could generate hazards, are present.
A major limitation of the simple pipelining techniques is that they all use in-order
instruction issue and execution: Instructions are issued in program order and if an instruction
is stalled in the pipeline, no later instructions can proceed. Thus, if there is dependence
between two closely spaced instructions in the pipeline, this will lead to a hazard and a stall.
If there are multiple functional units, these units could lie idle. If instruction j depends on a
long-running instruction i, currently in execution in the pipeline, then all instructions after j
must be stalled until i is finished and j can execute. For example, consider this code:
DIV.D
F0,F2,F4
ADD.D
F10,F0,F8
SUB.D
F12,F8,F14
Out-of-order execution introduces the possibility of WAR and WAW hazards, which
do not exist in the five-stage integer pipeline and its logical extension to an in-order floatingpoint pipeline.
Out-of-order completion also creates major complications in handling exceptions.
Dynamic scheduling with out-of-order completion must preserve exception behaviour in the
sense that exactly those exceptions that would arise if the program were executed in strict
program order actually do arise.
Imprecise exceptions can occur because of two possibilities:
1. The pipeline may have already completed instructions that are later in program order than
the instruction causing the exception, and