如果我的问题令人困惑,我很抱歉,但这是我想要做的例子,
让我说我有一个无符号long int = 1265985549二进制我可以把它写成01001011011101010110100000001101
现在我想把这个二进制32位数分成4位,就像这样,分别在这4位上工作
0100 1011 0111 0101 0110 1000 0000 1101
任何帮助,将不胜感激.
我在两个 $t 寄存器中加载了一个浮点双精度数,现在我想将它除以 (-4)(不使用 fp 指令)并将其存储回 $f 寄存器。
mfc1 $t0, $f0 #$f0 = 0x00000000
mfc1 $t1, $f1 #$f1 = 0x40240000
div $t1, $t1, -4
mfhi $t0 #move the remainder to $t0
mflo $t1 #move the quotient to $t1
mtc1 $t0, $f0
mtc1 $t1, $f1
# store the $f0 result in memory
# print X/(-4)
mov.d $f12, $f0
li $v0, 3
syscall
Run Code Online (Sandbox Code Playgroud)
但这给出了非常意外的结果,即 -2.231744757682269E231
任何帮助将不胜感激。