6. Experimental work
Design the instruction memory and instruction register components in Verilog HDL. Create the block diagram to connect the components as shown in the figure below.
a. Design a code in Verilog HDL and create the symbol of a 32-byte instruction memory (IM). (Refer to the appendix on how to create a symbol).
b. Save at least five different instructions inside the IM (use Verilog initial statement).
c. Design a code in Verilog HDL and create the symbol of the Instruction Register (IR) unit, as shown in the figure below. The unit should support sign extension.
d. Add the diagram below and connect it to the PC unit you designed in the previous lab.
c. Create a waveform (University program VWF) to simulate and verify your block diagram. Your waveform should show the encoded fields of all instructions in the IM.
32
Read address
Op (Instruction[31:26]) Rs (Instruction[25:21]) Rt (Instruction[20:16]) Rd (Instruction[15:11]) Shamt (Instruction[10:6]) Funct (Instruction[5:0]) 32-bits Sign Ext. Imm (Instruction[15:0])
Instruction 32 [31:0] Instruction Register Instruction memory
7. Thought Questions
To be provided by your instructor during the lab session
CE 437 Computer Design and Prototyping Spring 2020
Page 6 of 7