What data is in the word starting at address 0x1000000C? 0x00000003
What is the address of the word containing 0x00000002? 0x10000008
The contents of a word of memory may be any 32-bit pattern. The address of a word of memory is also a 32-bit pattern. Both types of data fit into a 32-bit register.
Sometimes you want
the contents of memory word
to be loaded
into a register.
For example, you may wish to load the
value 0x00000002.
This is done with the
lw
instruction.
Other times you want
the address of
a word in memory.
For example, you may wish to load the
address 0x10000008.
This is done with the
la
instruction.
la d,exp # load register $d with the address # described by the expression "exp" # "exp" is often a symbolic address # (pseudoinstruction)