mult

Operands

$reg, $reg

Multiply signed : Multiplies $t1 by $t2 as signed 32-bit integers. The 64-bit product is split: the upper 32 bits go into the HI register and the lower 32 bits go into the LO register. Use 'mfhi' to read HI and 'mflo' to read LO.

Variants

  • Multiply signed : Multiplies $t1 by $t2 as signed 32-bit integers. The 64-bit product is split: the upper 32 bits go into the HI register and the lower 32 bits go into the LO register. Use 'mfhi' to read HI and 'mflo' to read LO. mult $t1,$t2
# Multiply 6 by 7. Inspect HI:LO: 42 (HI=0, LO=42).
li $t0, 6
li $t1, 7
mult $t0, $t1
mflo $t2
mfhi $t3