Docsity

MIPS Datapath for Assignment 4 - Computer Architecture - Fall 2007 | ECE 3055, Assignments of Electrical and Electronics Engineering

Toggle sidebar
bg1
Summer 2007 ECE 3055
Assignment 4
Due Date: 11:59 pm, Monday July 9th, 2007.
1 Purpose:
To understand the operation of the pipelined MIPS datapath, particularly the timing
requirements for correctly dealing with forwarding and control and data hazards.
1.1 Assignment
As with Part I there are two components – a warm-up component designed to help you
become familiar with the datapath and an extension component.
1.1.1 Warm-up
1. To familiarize yourself with the model, compile and execute a few simple
programs. Study the trace and execution of the program that is provided. Study
the trace and convince yourself that the programs are indeed correctly executed.
Check the (brief) documentation associated with the model. The warm-up can be
discussed with your classmates.
a. Is this program execution correct? If not why not?
b. The datapath does not provide hardware support for correctly executing
branches? How many delay slots does the pipeline have?
c. What is the initial value of the stack pointer?
d. What value is placed on the read output of memory when the data memory
is not being read?
1.1.2 Extensions
There are three parts to this assignment.
1. Extend the data path to implement data forwarding for the supported instructions.
Your implementation should correctly execute all programs that have
dependencies between instructions supported by the datapath. Note that there will
still be a single delay slot in instances where there is a loadÆALU hazard.
2. Move the computation of the branch address and branch condition to the decode
stage to realize a single branch delay slot. Demonstrate the correct execution with
2 sample programs that fill branch and load delay slots with useful instructions.
3. Extend the datapath with a hazard detection unit that will perform the following
operations in hardware
a. Hazards between a load and an immediately following register-to-register
operation will be detected and a single stall cycle (bubble) will be inserted
into the pipeline.
b. The fetch unit will implement assume-not-taken policy for branches.
When a branch is actually taken, the incorrect instruction has to be flushed
and the instruction fetch continued at the branch target.
pf2

Partial preview of the text

Download MIPS Datapath for Assignment 4 - Computer Architecture - Fall 2007 | ECE 3055 and more Assignments Electrical and Electronics Engineering in PDF only on Docsity!

Summer 2007 ECE 3055

Assignment 4

Due Date: 11:59 pm, Monday July 9th^ , 2007.

1 Purpose:

To understand the operation of the pipelined MIPS datapath, particularly the timing requirements for correctly dealing with forwarding and control and data hazards.

1.1 Assignment

As with Part I there are two components – a warm-up component designed to help you become familiar with the datapath and an extension component.

1.1.1 Warm-up

  1. To familiarize yourself with the model, compile and execute a few simple programs. Study the trace and execution of the program that is provided. Study the trace and convince yourself that the programs are indeed correctly executed. Check the (brief) documentation associated with the model. The warm-up can be discussed with your classmates. a. Is this program execution correct? If not why not? b. The datapath does not provide hardware support for correctly executing branches? How many delay slots does the pipeline have? c. What is the initial value of the stack pointer? d. What value is placed on the read output of memory when the data memory is not being read?

1.1.2 Extensions

There are three parts to this assignment.

  1. Extend the data path to implement data forwarding for the supported instructions. Your implementation should correctly execute all programs that have dependencies between instructions supported by the datapath. Note that there will still be a single delay slot in instances where there is a loadÆALU hazard.
  2. Move the computation of the branch address and branch condition to the decode stage to realize a single branch delay slot. Demonstrate the correct execution with 2 sample programs that fill branch and load delay slots with useful instructions.
  3. Extend the datapath with a hazard detection unit that will perform the following operations in hardware a. Hazards between a load and an immediately following register-to-register operation will be detected and a single stall cycle (bubble) will be inserted into the pipeline. b. The fetch unit will implement assume-not-taken policy for branches. When a branch is actually taken, the incorrect instruction has to be flushed and the instruction fetch continued at the branch target.

Summer 2007 ECE 3055

1.2 Review

There will be a review session for the pipelined datapath code as well as to answer questions. This will be held on Monday July 2nd^ , 6-7 pm. The classroom will most likely be VL 457, but will confirm later this week. To get the most out of this review, and minimized unproductive time during the execution of the assignment, it is strongly suggested that you

  1. Read the documentation to understand the signal naming convention
  2. Run a simulation for 4μs. Study the trace and signals. Try to ensure you agree with the values that you see on the trace. Spending an hour or two with this exercise before attempting to do anything will be most productive.

2 Submissions Instructions

There is no submission requirement for the warm-up. For the extended datapath, submit the following in electronic format.

  1. A document briefly and precisely describing your modifications to implement each of the extensions. Specify which code blocks were modified & how and which code modules were added.
  2. Screen shots of traces of test cases for each of the three extensions documenting that they work. The screen shots should be a. Accompanied by text clearly describing the correct operation, or b. The screen shots should be marked (electronically) with comments demonstrating that the correct functionality, or c. Demonstrate the model in the laboratory to the TA. If you choose this option and successfully demonstrate all aspects of the assignment, then you only need to submit item 3 below. Note that the TA signoff should be based on established test cases constructed and verified prior to the meeting. The meeting only replaces the raw submission and does not replace any of the testing requirements.
  3. The complete VHDL code for the modified datapath. It should be in a form whereby all that needs to be done is compiling & execution (as in the case of the model that was provided to you). If this does not work, it will void item 2.c above.
  4. Submit a zip file with the preceding to the TA by 11:59 PM, Monday, July 9 th.

3 Grading Guidelines

  1. A complete and correct design as in items 1 & 2 of the submission a. Forwarding: 10 pts. b. Delay slot execution: 5 pts c. Hazard detection: 20 pts.
  2. Compiles and executes all three elements are implemented): 35 pts (10 pts, 5 pts, 20 pts)
  3. Execution is correct: 25 pts (10 pts, 5 pts, 10 pts)
  4. Clarity of description and documentation (including code documentation): 5 points