Skip to content

Will-Li-zw/ECSE_425_Final

Repository files navigation

ECSE_425_Final :trollface:

Welcome to the repository of Group06 ECSE425 Final Project - Pipelined Processor

How to run our program?:partying_face:


Unit Tests:

Unit under Testing Directory File required Runtime
Fetch_stage unit test fetch stage fetch_stage.vhd + fetchStage_tb.vhd 15ns
Decode_stage*** unit test decode stage decode_stage.vhd + decodeStage_tb.vhd + register_file.vhd 20ns
Register_file component test register file register_file.vhd + register_file_tb.vhd 20ns
Execute_stage unit test execute stage execute_stage.vhd + executeStage_tb.vhd + TWOMUX.vhd + ADD.vhd + FIVEMUX.vhd + ALU.vhd 16ns
ALU component test ALU ALU.vhd + ALUUnit.vhd 10ns
Memory_stage unit test memory stage memory_stage.vhd + memoryStage_tb.vhd 20ns
Writeback_stage unit test write back stage writeback_stage.vhd + writebackStage_tb.vhd + TWOMUX.vhd 6ns
Memory component test memory memory.vhd + memory_tb.vhd 15ns

*** Decode stage unit testing may have compilatoin errors for one file. In that case, compile only the failed file again and it will compile successfully. It is an compile order issue.


Benchmark1 -- Entry point

  1. Go to the benchmark1 directory
  2. Use Modelsim to open the project file: benchmark1.mpf
  3. Make sure all files needed to run are included: image
  4. Run the command: source benchmark1_tb.tcl in the console
  5. The console may report error:
    image
  6. Ignore the error and goto wave window
  7. Make sure the time to run is 6.5ns for testbench1
  8. Show the result: image

Benchmark2 -- Fibonacci 🈶

Note: In this project, we assume that the end of program is not an infinite loop instruction. Our CPU will determine when is the end of the instruction by itself since when loading the instructions from "program.txt", we assigned the rest of instruction memory as undefined.

  1. Go to the benchmark2 directory
  2. Use Modelsim to open the project file: processor.mpf
  3. Make sure all files needed to run are included:
    image
  4. Run the command: source final_tb.tcl in the console
  5. The console may report error: image
  6. Ignore the error and goto wave window
  7. Make sure the time to run is 55ns for testbench2
  8. Show the result:
    image