TSK3000A Core Instruction - DIVU

Frozen Content

Instruction:

Divide Unsigned Word

Assembler Format:

divu rC, rA, rB

Example:

divu $2, $3, $4

Description:

Divides the contents of GPR rA by the contents of GPR rB, treating both operands as 32-bit unsigned positive values. The quotient word is loaded into special register LO and also GPR rC. The remainder word is loaded into special register HI. Both quotient and remainder values will always be positive.

If rC is not specified, $0 will be used by default.

Operation:

LO <-- (Unsigned) rA div (Unsigned) rB
rC <-- (Unsigned) rA div (Unsigned) rB
HI <-- (Unsigned) rA mod (Unsigned) rB

Instruction Type:

R-Type

Instruction Fields:

rA = Register index of operand A

rB = Register index of operand B

rC = Register index of destination

Encoding:

31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
0 0 0 0 0 0
rA
rB
rC
0 0 0 0 0 0 1 1 0 1 1

Latency: 1

You are reporting an issue with the following selected text and/or image within the active document: