All MIPS instructions are 32 bits, or 4 bytes, long. The fixed length is almost universal in RISC processors.
When MIPS instructions are classified according to coding format, they fall into four categories: R-type, I-type, J-type, and coprocessor. These formats are closely related to the execution activities in the processor circuitry.
The coprocessor coding format is not described here. Although the use of a coprocessor is advantageous for an embedded processor, desktop and server processors have not used them for about 20 years.
Many MAL instructions get expanded into 2 or 3 MIPS instructions. These expansions are often used to deal with immediate operands and idiosyncrasies of the MIPS instruction set. Some of these expansions use $at as a temporary register.
MIPS assemblers normally make the following expansions. For some instructions more than one expansion may be applied. There are other expansions that are not described here.
li reg, immis expanded to
lui reg, imm[31:16] ori reg, reg, imm[15:0]
move reg1, reg2is expanded to
or reg1, reg2, $0
la reg, labelis expanded to
li reg, labelAddress
load or store reg, labelis expanded to
la $at, label load or store reg, 0($at)
op reg1, reg2, immis expanded to
li $at, imm op reg1, reg2, $at