You are on page 1of 1

Name:

RegDst Branch Jump MemRead MemToReg ALUOp  MemWrite  ALUSrc  RegWrite ALU control bits

add 1 0 0 0 0 10 0 0 1 0010

sub 1 0 0 0 0 10 0 0 1 0110

and 1 0 0 0 0 10 0 0 1 0000

or 1 0 0 0 0 10 0 0 1 0001

slt 1 0 0 0 0 10 0 0 1 0111

addi     0  0 0 0 0 00 0 1 1 0010

ori       0  0 0 0 0 11 0 1 1 0001

lw 0 0 0 1 1 00 0 1 1 0010

sw X 0 0 0 X 00 1 1 0 0010

beq X 1 0 0 X 01 0 0 0 0110

j X 0 1 0 X XX 0 X 0 XXXX

(ALUOp is two bits)


Note: ALUOp for ori is not given in the book – use 11
You should figure our what ALUOp for addi should be

Instruction Opcode function code (for R-type)

add 000000 100000


sub 000000 100010
and 000000 100100
or 000000 100101
slt 000000 101010

addi 001000
ori 001101
lw 100011
sw 101011
beq 000100
j 000010

You might also like