Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

A simple MIPS single-clock data path is given below. (a) Get the machine languag

ID: 3839041 • Letter: A

Question

A simple MIPS single-clock data path is given below.

(a) Get the machine language of the instruction “lw $s0, 100($s1)” (refer to green reference card)

_________________________________________________

(b) Highlight the active data path and mark the control signals and selection signals of multiplexers

PCH Ad Ad left 2 ALUO Branch Instr 31-261 Control Unit rc RegWrite RegDst ovf 25-21 1 Read Addr Instruction Register Read Memory nstr[20.16 Data 1 Zer Read Addr 2 Read Address nstr 31-0 File ALU rite Addr Rea Data 2 nstr 1 Write Data 11] Sign n str 15 ALU Extend 32 16 contro L Instr[5-0] PCSrc Merm Read MemitoReg Address Memory Read Data N rite Data

Explanation / Answer

I have designed the Machine language fo the instruction and highlighting of active data path which will be useful in handling the signals and multiplexers. I have added the comments for each section and the final output of it.

Let me give you an overview and brief you in step-by-step manner:-

A)

Step-1:

The initial step is to know the memory management of the machine language is present.Moreover, The bytes should be counted for each memory allocation.

Example:-

The 232 bytes with byte addresses ranging the values from 0 to 232 - 1

Step-2:

The next step is to transfer the data to their specific instructions i.e, The offset values will be added to their respective base register unit.

Example:-

lw - The load register is used to load a value from memory section,

sw - The load register is used to store a value to memory section,

Step-3:

The final step is to define the Instruction “load word (lw)” which is the family of I-type format.

Example:-

The structure of I- type format is Opcode, base, destination, and address.

Machine Language Code:-


# The add function is executed first

loop:

add $s1,$s2,$s3
sub $s1,$s2,$s3
addi $s1,$s2,5
ori $s1,$s2,5

# It laods the register s1 and the s2.

lw $s1,100($s2)

# It will store the value of s1 and the s2 to memory location

sw $s1,100($s2)

bne $s4,$s5,
beq $s4,$s5
slt $t1,$s2

end_loop

Machine Language Output:-

B)

Step-4:

The data path is being calculated by the program counter which contains the memory instructions. The structure of active data paths are 32- bit register produced by using 32 D flip-flops.

Example:-

The C is a CLK signal which is used to assert into the resigter.

Step-5:

The next comes the datapath which integrates the 32-bit ALU system.

Example:-

Step-6:

The final step is to finalize the is to control the signals in two different ways i.e, The Instr 5:0 and  ALUOp1:0

Example:-

Opcode Source Destination Address 35 S2 S1 100
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote