Arithmetic/Integer: Difference between revisions

Line 40:
From the principles of operation: Operands are signed and 32 bits long.
Negative quantities are held in two's-complement form.
====<br>'''Multiplication====:'''<br>
The product of the multiplier (the second operand) and the multiplicand
(the first operand) replaces the multiplicand. Both multiplier and
multiplicand are 32-bit signed integers. The product is always a 64-bit
signed integer and occupies an even/odd register pair.
====<br>'''Division====:'''<br>
The dividend (first operand) is divided by the divisor (second operand)
and replaced by the quotient and remainder. The dividend is a 64-bit
Line 51:
A 32-bit signed remainder and a 32-bit signed quotient replace the dividend
in the even-numbered and odd-numbered registers, respectively.
<lang 360asm>* Arithmetic/Integer 04/09/2015
* Arithmetic/Integer 04/09/2015
ARITHINT CSECT
USING ARITHINT,R12
Line 90 ⟶ 89:
BUF DC CL12' '
YREGS
END ARITHINT</lang>
</lang>
{{out}}
<pre>
Line 100 ⟶ 98:
R 9
</pre>
 
 
 
=={{header|6502 Assembly}}==
1,392

edits