the assembler temporary register.
assembler temporary register
is reserved for use in the
machine instructions that pseudoinstructions
are translated into.
Often a pseudoinstruction
is implemented as a short sequence of
machine instructions that use
Here is how
was translated in the example:
la $t0,val2 == lui $1,4097 ori $8,$1,8
a pseudoinstruction has the
same mnemonic as a basic assembler instruction.
lw (load word)
is a basic assembler instruction.
As an assembler instruction, it is used like this:
lw $t1,8($t0) # load the word at address $t0+8
designates the address with a displacement
(eight, in this case) to add to a base register
$t0, in this case).
This corresponds exactly to one machine instruction.
There is no other form for the non-extended
However, with the extended assembler,
the following pseudoinstruction
can be used:
lw $t1,exp # load value at address exp
The machine instruction
uses a base register to form an address.
must be translated into instructions that also use a base register
(since this is the only way MIPS instructions can address memory.)
What base register is used?