MIPS Standard Instructions

The following MIPS standard instructions MUST be supported in the DCoreWars game engine (both uniprocessor and distributed versions). For details of the binary encoding of these instructions, refer to the attached ``MIPS Assembly Language'' handout and/or the online reference documentation.

Standard MIPS instructions that MUST be supported by the RVM of the DCoreWars game.
Instruction Short description
Branch/Jump instructions
beq Branch on equal
bne Branch on not equal
bgtz Branch on greater than zero
bgez Branch on greater than equal zero
bltz Branch on less than zero
blez Branch on less than equal zero
j Unconditionally jump
jr Unconditionally jump to register
Arithmetic instructions
add Add signed quantities
addi Add signed immediate
addu Add unsigned quantities
addiu Add unsigned immediate
sub Subtract
subu Subtract unsigned quantities
mult Multiply
divu Divide
and Logical AND
andi Logical AND, immediate
or Logical OR
ori Logical or, immediate
nor Logical NOR
xor Logical XOR
xori Logical XOR, immediate
sll Shift left logical
sllv Shift left logical variable
srl Shift right logical
srlv Shift right logical variable
sra Shift right arithmetic
srav Shift right arithmetic variable
Conditional instructions
slt Set less than
slti Set less than immediate
sltu Set less than, unsigned quantities
sltiu Set less than immediate, unsigned
Data movement instructions
lw Load word
sw Store word
mfhi Move from HI
mflo Move from LO
Miscellaneous instructions
syscall System call (see below)
   

Technically, many of these instructions detect overflow. For the purposes of this project, however, design groups MAY ignore that and treat all operations as ignoring overflow.

Terran Lane 2004-03-29