Okay, I'm reading over last year's final, and there is one section that I just can't seem to figure out:
Now, I don't see how she got that answer. When I write out the addresses in full binary I get:
X: 0000 0000 0000 0000 1111 1000
Y: 0000 1000 1100 1010 0100 0111
It's seems to me if you took a byte from 3 off of X you would get this portion:
000[0 0000 000]0 0000 1111 1000
but somehow she get's -8? There are not even that many ones in a row anywhere? Where is she getting that from? Thanks.
code:<HR>Code:.data X: .word 0xf8 Y: .word 0x8ca47<P>la $si,X lb $t0,3($s1)<P>What's in $t0? Answer: -8 or 0xfffffff8
Now, I don't see how she got that answer. When I write out the addresses in full binary I get:
X: 0000 0000 0000 0000 1111 1000
Y: 0000 1000 1100 1010 0100 0111
It's seems to me if you took a byte from 3 off of X you would get this portion:
000[0 0000 000]0 0000 1111 1000
but somehow she get's -8? There are not even that many ones in a row anywhere? Where is she getting that from? Thanks.