CPC G06F 7/49915 (2013.01) [G06F 7/4873 (2013.01); G06F 7/49936 (2013.01); G06F 7/49957 (2013.01)] | 20 Claims |
9. A system for performing computations, the system comprising:
one or more processors and a non-transitory computer readable storage having software instructions stored thereon configured to cause the one or more processors to:
receive a first operand in a data format, wherein the first operand is a first decimal number;
receive a second operand in the data format, wherein the second operand is a second decimal number, wherein the second operand includes four fields: a sign bit, a 5-bit leading digit field, a biased exponent field, and a trailing coefficient field, wherein the leading digit field specifies whether the second decimal number is exact, an inexact decimal number with a trailing low fraction, or an inexact decimal number with a trailing high fraction; and
perform a computation operation comprising digit injection, in which a result of the computation operation encodes a leading digit field according to the coefficient field, exactness of a fraction field, and whether the result is overflow or not a number, wherein the trailing low fraction or the trailing high fraction of the result are replaced by decimal values, respectively, with an injected Binary-Coded Decimal fraction digit.
|