Mipsref
Mipsref
.word i
add $d, $s, $t
sub $d, $s, $t
mult $s, $t
multu $s, $t
div $s, $t
divu $s, $t
mfhi $d
mflo $d
lis $d
lw $t, i($s)
sw $t, i($s)
slt $d, $s, $t
sltu $d, $s, $t
beq $s, $t, i
bne $s, $t, i
jr $s
jalr $s
addi $t, $s, i
ji
jal i
Instructions
iiii iiii
0000 00ss
0000 00ss
0000 00ss
0000 00ss
0000 00ss
0000 00ss
0000 0000
0000 0000
0000 0000
1000 11ss
1010 11ss
0000 00ss
0000 00ss
0001 00ss
0001 01ss
0000 00ss
0000 00ss
0010 00ss
0000 10ii
0000 11ii
iiii
ssst
ssst
ssst
ssst
ssst
ssst
0000
0000
0000
ssst
ssst
ssst
ssst
ssst
ssst
sss0
sss0
ssst
iiii
iiii
iiii
tttt
tttt
tttt
tttt
tttt
tttt
0000
0000
0000
tttt
tttt
tttt
tttt
tttt
tttt
0000
0000
tttt
iiii
iiii
iiii
dddd
dddd
0000
0000
0000
0000
dddd
dddd
dddd
iiii
iiii
dddd
dddd
iiii
iiii
0000
0000
iiii
iiii
iiii
iiii
d000
d000
0000
0000
0000
0000
d000
d000
d000
iiii
iiii
d000
d000
iiii
iiii
0000
0000
iiii
iiii
iiii
iiii
0010
0010
0001
0001
0001
0001
0001
0001
0001
iiii
iiii
0010
0010
iiii
iiii
0000
0000
iiii
iiii
iiii
iiii
0000
0010
1000
1001
1010
1011
0000
0010
0100
iiii
iiii
1010
1011
iiii
iiii
1000
1001
iiii
iiii
iiii
R
I
R
R
R
R
R
R
R
R
R
I
I
R
R
I
I
R
R
I
J
J
$d = $s + $t
$d = $s - $t
hi:lo = $s * $t
hi:lo = $s * $t
lo = $s / $t; hi = $s % $t
lo = $s / $t; hi = $s % $t
$d = hi
$d = lo
$d = MEM[pc]; pc = pc + 4
$t = MEM [$s + i]:4
MEM [$s + i]:4 = $t
$d = 1 if $s < $t; 0 otherwise
$d = 1 if $s < $t; 0 otherwise
if ($s == $t) pc += i * 4
if ($s != $t) pc += i * 4
pc = $s
temp = $s; $31 = pc; pc = temp
$t = $s + i
pc = high4(pc).(i<<2)
$31 = pc; pc = high4(pc).(i<<2)
When a word is stored to memory location 0xffff000c, the least-significant byte (eight bits) of the word are sent to the standard output.
Loading a word from memory location 0xffff0004 places the next byte from standard input into the least-significant byte of the destination register.