is it this instruction is correct Using SPIM ?
add $t1,$zero,-1
after run program the $t1 is fill by "ffffffff"
is it this instruction is correct Using SPIM ?
add $t1,$zero,-1
after run program the $t1 is fill by "ffffffff"
You want addi
instead of add
addi $t1, $zero, -1
The addi
instruction sign-extends the 16-bit immediate, so it should place 0xffffffff
in $t1
.