


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!



The control unit controls the operation of the datapath. In this lab, you will implement a horizontally microprogrammed control unit for your SRC datapath (Lab 3) in SMOK using a PLA (programmable logic array). This will complete the 2-cycle SRC implementation you’ve been building. Your design will now be able to execute programs written with the subset of the SRC instruction set discussed in class.
NOTES:
Lab Objectives/Directions:
In this lab you will:
Lab 4 Checkoff Sheet Name:________________________ Email ID:__________________________ Date: ______________________ NOTE: If you can get Checkoff #2, there is no need to get checkoffs for the table in checkoff #1. Checkoff 1: Set the memory and register contents to the values listed in the respective columns for each instruction, then test the operation of your datapath. The IR value contains the encoding of the instruction:
Instruction Mem Value Register Value Correct Execution? ld r1, 0x10 Mem[0x10]=0x10 IR=0x ld r3, 0x14(r1) Mem[0x24]=0x24 IR=0x08c r1=0x ldr r5, 0x18 Mem[0x18]=0x01a Mem[0x1018]=0x104a
IR=0x117ff00c PC=0x
la r15, 0x10a8 Mem[0x10a8]=0xffff IR=0x2bc010a lar r15, 0x70 n/a IR=0x33c PC=0x0000104c add r2, r1, r3 n/a IR=0x r1=0x4, r3=0x addi r4, r5, 3 n/a IR=0x690a r5=0x sub r6, r7, r9 n/a IR=0x718e r7=0x8, r9=0x and r8, r11, r13 n/a IR=0xa216d r11=0xa, r13=0x andi r10, r2, 0x
n/a IR=0xaa r2=0x or r12, r4, r6 n/a IR=0xb r4=0xa, r6=0x ori r14, r8, 0x0f0f
n/a IR=0xbb900f0f r8=0xf0f brl r14, r15 n/a IR=0x4b9e PC=0x r15=0x10a brlpl r14, r15, r3 Mem[10a4]=0xf8000000 IR=0x4b9e3004, PC=0x1000, r15=0x10a4, r3=0xf brlpl r14, r15, r3 Mem[10a4]=0xf8000000 IR=0x4b9e3004, PC=0x1000, r15=10a4, r3=0x brzr r14, r1 n/a IR=0x401c1002, r14=0x1000, r1=0x brzr r14, r1 n/a IR=0x401c1002, r14=0x1000, r1=0x br r15 Mem[10a4]=0xf8000000 IR=0x401e0001, r15=10a st r0, 0x0100 n/a IR=0x18000100, r0=0x st r1, 0x0104(r0) n/a IR=0x18400104, r0=0x4, r1=0xbeef str r5, 0x0114 n/a IR=0x217ff098, r5=0x
Checkoff #2: If your datapath successfully executes the program stored in lab3binary.smokmem , then you will receive full credit for the lab without checkoffs needed for the table in checkoff 1. _________________________