
Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!

Department of Computer Science
1). Indicate the type of data hazards (RAW, WAR, and WAW) that exist between the following instructions.
i 1 Add R 1 , R 2 , R 3 -- R 1 = R 2 + R 3 i 2 Add R 4 , R 1 , R 4 -- R 4 = R 1 + R 4 i 3 Add R 3 , R 1 , R 2 -- R 3 = R 1 + R 2 i 4 Add R 1 , R 1 , R 4 -- R 1 = R 1 + R 4
2) Draw a chart to show how the following instructions are executed using Tomasulo's method. The instruction pipeline has five stages, IF, ID, OF, EX, and WB, and each stage takes 1 clock cycle. The system has one adder and two reservation stations.
add R1, R3, R add R3, R1, R add R3, R2, R
3) Use scoreboard method. The instruction pipeline has four stages, IF&ID, OF, EX, and WB as in the text book. Each stage takes 1 clock cycle, except for the EX stage of the multiplication, which takes 3 cycles. The system has one adder and two multipliers.
mul R5, R1, R2, mul R2, R2, R add R2, R3, R