Dynamic Scheduling


Scoreboard

We'll assume a machine with 2 integer units, 2 FP add units, 1 FP multiply unit, and 1 FP divide unit. A scoreboard consists of three parts: the instruction status, the functional unit status, and the register status. These parts are shown and explained below.

Instruction status

InstructionIssueRead operandsExecutionWrite result
LD    F2,0(R1)
x
-
-
-
ADDD  F6,F2,F4
x
-
-
-
MULTD F8,F6,F0
x
-
-
-
LD    F10,-8(R1)
x
-
-
-
ADDD  F12,F10,F4
x
-
-
-
MULTD F14,F12,F0
-
-
-
-
SUBI  R1,R1,#16
-
-
-
-
BNEZ  R1,Loop
-
-
-
-

Functional unit status

NameBusyOpFiFjFkQjQkRjRk
Int1YesLoadF2R1
-
-
-
No
-
Int2YesLoadF10R1
-
-
-
No
-
Add1YesAddF6F2F4Int1
-
NoYes
Add2YesAddF12F10F4Int2
-
NoYes
Mult1YesAddF8F6F0Add1
-
NoYes
Div1No
-
-
-
-
-
-
-
-

Register result status

F0F2F4F6F8F10F12F14
-
Int1
-
Add1Mult1Int2Add2
-

The instruction status table indicates which stage a particular instruction is in. In this example, we assume that the table is large enough so it can fit all the instructions. The functional unit status table indicates the state of the functional unit. The fields are as follow:

The register result status table indicates which functional units are writing to which registers.

In the tables above, we have filled out the initial status of the tables, assuming all the instructions had been fetched into the instruction status table. We issue instructions sequentially until we encounter a WAW hazard or we run out of functional units. In this case, we ran out of functional units. Note that we have issued five instructions at once. This may not be realistic depending on the particular machine. For now, we will assume this is legal.

Continue...


Back to Scoreboarding


Author: Allan Tong
Contact actong@wam.umd.edu