我试图实现在MIPS以下与二维数组挣扎在装配
X是双精度浮点的二维阵列(矩阵) 号码和Y是32的二维阵列位整数。 尝试写代码以下
Z= (X[i][j] + Y[i][j])
现在我不知道如何在MIPS声明这些数组:到目前为止,我已经写了一些主程序
,但不知道如何实现它们在.data
部分
.data
.text
.main:
mtc1 $0, $f0
cvt.d.w $f0, $f0
# $a1 is the address of the first element of x
l.a $r1, $a1
# $a2 is the address of the first element of y
l.a $r2, $a2
addi $r4, $0, 30
add.d $f8, $f0, $f0
如何查找和阅读组装文档? – 2012-08-07 12:20:18
[可以在MIPS程序集中声明这样的二维数组吗?]可能的重复?(http://stackoverflow.com/questions/11828209/is-it-possible-to-declare-such-2d-arrays-in-mips -assembly) – 2012-08-07 12:20:46
@AlexeyFrunze - 我做了,但没有找到任何信息 – 2012-08-07 12:23:14