86 Arithmetic Ten's Complement for BCD The addition of the ten's complement of a number is used in lieu of a subtraction mechanism. If the signs of the two numbers to be summed are different, one of the numbers is complemented (it doesn't really matter which one), before the addition. The ten's complement of a number with n digits to the left of the decimal point is - x = Ian - X The ten's complement of a floating-point number has the same exponent as the original number.
Since the mantissa (M) of a full-precision number can be assumed to have the decimal point implied after D1, then the number must be less than 10 (but greater than 0) and the ten's complement of a mantissa becomes - M = 10 - M Accordingly, all that is necessary to complement a floating-point number is to complement the mantissa. It is immaterial whether the mantissa is treated as a 12-digit integer or as a number between a and 10; the same sequence of digits results. There are two instructions for doing ten's complements - CMX and CMY. The only difference between them is that CMX operates on the Arl register and CMY operates on the Ar2.
CMX and CMY leave the exponent word of a full-precision number completely alone. This means that the sign of the mantissa~ and the entire exponent are left unchanged in a ten's complement by CMX and CMY.