C335 Homework #7

$30.00

Category: Tags: , , , , You will Instantly receive a download link for .zip solution file upon Payment || To Order Original Work Click Custom Order?

Description

5/5 - (2 votes)

Points: : 40 points
PART I (10 POINTS)
Using a drawing similar to what we used in lecture notes, show the forwarding paths needed to
execute the following four instructions:
add $3, $4, $6
sub $5, $3, $2
lw $7, 100($5)
add $8, $7, $2
PART II (10 POINTS)
Identify all of the data dependencies in the following code. Which dependencies are data hazards
that will be resolved via forwarding? Which dependencies are data hazards that will cause a stall?
add $3, $4, $2
sub $5, $3, $1
lw $6, 200($3)
add $7, $3, $6
PART III (10 POINTS)
Here is a series of address references given as word addresses: 2, 3, 11, 16, 21, 13, 64, 48, 19, 11,
3, 22, 4, 27, 6, and 11. Assuming a direct-mapped cache with 16 one-word blocks that is initially
empty, label each reference in the list as a hit or a miss and show the final contents of the cache.
PART IV (10 POINTS)
Here is a series of address references given as word addresses: 2, 3, 11, 16, 21, 13, 64, 48, 19, 11,
3, 22, 4, 27, 6, and 11. Show the hits and misses and final cache contents for a direct-mapped
cache with four-word blocks and a total size of 16 words.