<<< Basic addressing mode | Index | Sub-word addressing mode >>> |
Macro instructions to read/write a specific address
lw $t1, $t2 # $t1 = Memory[$t2] sw $t1, $t2 # Memory[$t2] = $t1
Macro instructions for reading/writing with labels
lw $t1, label # $t1 = Memory[label] lw $t1, label+4 # $t1 = Memory[label+4] lw $t1, label($t2) # $t1 = Memory[label+$t2] sw $t1, label # Memory[label] = $t1 sw $t1, label+4 # Memory[label+4] = $t1 sw $t1, label($t2) # Memory[label+$t2] = $t1
<<< Basic addressing mode | Index | Sub-word addressing mode >>> |