[ ¤³¤Î¥á¥Ã¥»¡¼¥¸¤Ø¤ÎÊÖ»ö ]
[ ÊÖ»ö¤ò½ñ¤¯ ]
[ home.html ]
Åê¹Æ¼Ô¡§
movem.l d0-d7/a0-a5,-(sp) @ h012.p066.iij4u.or.jp on 97/9/21 01:31:13
In Reply to: ¥¢¥»¥ó¥Ö¥é¤Ë¾Ü¤·¤¤Êý¶µ¤¨¤Æ¤¯¤À¤µ¤¤
posted by 68user @ oryo.inforyoma.or.jp on 97/9/20 19:44:29
> a[i] = h + a[i];
>
> ¤òMIPS¤Î¥¢¥»¥ó¥Ö¥é¤Ç½ñ¤¯¤È
> # $18=h¡¢$19=i*sizeof(i)¡¢Astart=&a[0]
>
> lw $8,Astart($19)¢³ # $8=a[i]
> add $8,$18,$8¢³¢³¢³ # $8+=h
> sw $8,Astart($19)¢³ # a[i]=$8
>
> ¤È¤Ê¤ê¤Þ¤¹¤¬¡¢lw¤ÎAstart¤ÎÉôʬ¤Ï¥Þ¥·¥ó¸ì¤Ç¤Ï16bitʬ¤·¤«
> »ØÄꤹ¤ë¤³¤È¤¬¤Ç¤¤Þ¤»¤ó¡£¤¹¤ë¤È&a[0]>=2^16¤Î¾ì¹ç¤É¤¦¤Ê¤ë
> ¤ó¤Ç¤·¤ç¤¦¤«¡©
>
Íý²ò¤¹¤ë¤Î¤Ë»þ´Ö¤¬¤«¤«¤ê¤Þ¤·¤¿...¡£(^^;)
¤ª¤½¤é¤¯¡¢Astart¤ÎÉôʬ¤Ï¥¢¥É¥ì¥¹¤ò»ØÄꤹ¤ë¤È¤³¤í¤Ç¤Ï¤Ê¤¤¤È»×¤¤¤Þ¤¹¡£
ÉáÄ̤Ï$19¤ò¥Ù¡¼¥¹¥¢¥É¥ì¥¹¤È¤·¤Æ¡¢¤½¤³¤«¤é¤Î¥ª¥Õ¥»¥Ã¥È¤òÄê¿ô¤Ç»ØÄꤹ¤ë¾ì¹ç¤Ë»ÈÍѤµ¤ì¤ë¤Î¤Ç¤Ï¡©
Îã) a[2]¤ò¥¢¥¯¥»¥¹¤¹¤ë¾ì¹ç¡¡( $19=&a[0],Size=sizeof(a[0]) )
¡¡lw $8,Size*2($19)¡¡¡¡# $8=a[2]
¤³¤ó¤Ê´¶¤¸¤Ç¤¹¡£
¾åµ¤Î¤è¤¦¤Ëa[i]¤ÎÍͤʥ¢¥¯¥»¥¹¤ò¹Ô¤¦¾ì¹ç¤Ï¡¢¤½¤ÎÅÔÅÙ¡¢¼«Ê¬¤ÇÀäÂÐ¥¢¥É¥ì¥¹¤òµá¤á¤Æ¤ä¤ëɬÍפ¬Í¤ê¤Þ¤¹¡£
# ¤ä¤Ã¤Ñ¥¢¥»¥ó¥Ö¥é¤Ï68·Ï¤À¤è¤Ê¤¡
|