| Octal Order Code | Nmenonic | Execution |
|---|---|---|
| 040 | MPY X N(M) | Multiply The MPY instruction multiplies the contents of X by the contents of N(M). The double length product is left in XX*. The sign bit of X* is always set to zero. C is not used and will be left clear. V will be set if both factors have B0 = 1 and all other bits = 0 (i.e. the fraction -1.0). In this case, the result in X, will have B0 = 1, B1 to B23 = 0, and in X*, B0 to B23 = 0 (i.e. the double-length fraction -1.0). Modification This statement has an M field. When modified, the least significant 15 bits of N + M are taken as the operand. In the extended data mode, the least significant 22 bits of N + M are taken as the operand. |
| 041 | MPR X N(M) | Multiply and Round The MPR instruction multiplies the contents of X by the contents of N(M), producing a double length product in XX*. One is then added to the B1 position of X*, causing a carry into X if B1 of X* is one. The result is thus a single-length product in X. The sign bit of X* is always set to zero. C is not used and will be left clear. V will be set if both factors have B0 = 1 and all other bits = 0 (i.e. the fraction -1.0). In this case, the result will have -1.0 in X. Modification This statement has an M field. When modified, the least significant 15 bits of N + M are taken as the operand. In the extended data mode, the least significant 22 bits of N + M are taken as the operand. |
| 042 | MPA X N(M) | Multiply and Accumulate The MPA instruction causes the contents of X to be multiplied by the contents of N(M). The contents of X* are added to the less significant half of the result and the double length answer is left in XX*. The sign bit of X* is always set to zero. The contents of N(M) are unaltered, C is not used and will be left clear. V will be set if both factors have B0 = 1 and all other bits = 0 (i.e. the fraction -1.0) and the initial content of X* is positive or zero. Modification This statement has an M field. When modified, the least significant 15 bits of N + M are taken as the operand. In the extended data mode, the least significant 22 bits of N + M are taken as the operand. |
| 043 | CDB X N(M) | Convert Decimal to Binary The CDB instruction multiplies the double length binary number in X and X* by ten and adds in the character specified in N(M), having first checked that this character is numeric. If the specified character is not in the range 0 to 9, XX* and V will be unchanged, and C will be set. If B0 of X is originally 1, V may be set and an incorrect answer given in X; the answer in X*, however, is unaffected by the previous contents of X. If B0 of X* is originaaly 1, an incorrect answer will be given. C is not used and but will be set if a non-numeric character is encountered, otherwise left clear. V will be set if XX* contains more than the representation of 1/10 as a double length fraction, otherwise left unchanged. Modification This statement has an M field. When modified, the least significant 15 bits of N + M are taken as the operand. In the extended data mode, the least significant 22 bits of N + M are taken as the operand. |
| 044 | DVD X N(M) | Unrounded Double Length Divide The double length dividend in X and X* is divided by the single length number in N(M). The single length quotient is left in X* and the remainder in X. The double length dividend and the single length divisor may be integers, fractions or mixed numbers. (If the numbers have fractional parts, the number of bits after the binary point in the quotient is equal to the difference between the number of bits after the binary points in the dividend or divisor.) Negative numbers are catered for and a correctly signed quotient is produced. A remainder is left in X which satisfies the following equation: Remainder = Dividend - Quotient x Divisor. The remainder will always have the same sign as the divisor. The contents of N(M) are unaltered. C is not used and will be left clear. V will be set for the following conditions:
|
| 045 | DVR X N(M) | Rounded Double Length Divide The double length dividend in X and X* is divided by the single length number in N(M). The single length rounded quotient is left in X* after 2-24 has been added to effect the rounding. The double length dividend and the single length divisor may be integers, fractions or mixed numbers. (If the numbers have fractional parts, the number of bits after the binary point in the quotient is equal to the difference between the number of bits after the binary points in the dividend or divisor.) Negative numbers are catered for and a correctly signed quotient is produced. The contents of N(M) are unaltered. A remainder is left which satisfies the following equation: Remainder = Dividend - Quotient x Divisor. C is not used and will be left clear. V will be set for the following conditions:
|
| 046 | DVS X N(M) | Single Length Divide The single length number in X* is divided by the single length number in N(M). Although X is written in the accumulator field of the DVS statement, the dividend must be placed in X*: the initial content of X is irrelevant. The results of the operation are placed in X and X*, X holding the remainder and X* the unrounded quotient. The single length dividend and the single length divisor may be integers, fractions or mixed numbers. (If the numbers have fractional parts, the number of bits after the binary point in the quotient is equal to the difference between the number of bits after the binary points in the dividend or divisor.) Negative numbers are catered for and a correctly signed quotient is produced. A remainder is left in X which satisfies the following equation: Remainder = Dividend - Quotient x Divisor. The remainder will always have the same sign as the divisor. The contents of N(M) are unaltered. C is not used and will be left clear. V will be set for the following conditions:
|
| 047 | CBD X N(M) | Convert Binary to Decimal The CBD instruction multiplies the positive double length binary fraction in X and X* by ten. The integral part of the product is then stored as a decimal character in the position specified by N(M), and the fractional part is left in XX*. An incorrect result will be given if B0 of X or X* is initially 1. Non-significant zeros in the resultant decimal number will be replaced by spaces if MODE has been set to 1. If the integral part of the product is not zero, MODE is set equal to 0 so that further zeros are treated as significant. C is not used and will be left clear. V is not used and remains unchanged. Modification This statement has an M field. When modified, the least significant 15 bits of N + M are taken as the operand. In the extended data mode, the least significant 22 bits of N + M are taken as the operand. |