In MIPS, what are HI and LO

前端 未结 3 1782
感动是毒
感动是毒 2020-12-24 07:06

I\'m reading about division in MIPS and I\'ve found that div

Divides $s by $t and stores the quotient in $LO and the remainder in $HI

<
3条回答
  •  盖世英雄少女心
    2020-12-24 07:42

    HI and LO are not numbered registers, IIRC. They are only used to store the results of operations that would not fit in a single register (e.g. multiplying two 32-bit integers could result in a 64 bit integer, so the overflow goes in HI).

    edit: according to this class description, they are indeed special registers, so they are not numbered, and only accessible using special commands.

提交回复
热议问题