dquaq
Decimal Quantize Quad-Precision
Adjusts exponent of 128-bit DFP number.
Details
Quantizes a 128-bit decimal floating-point number in vA to match the exponent of the reference value in vB, producing a result in vD. The operation adjusts the exponent and coefficient of the source operand while preserving the value's significance. Rounding is performed if necessary according to the current DFP rounding mode in FPSCR. The instruction is part of the Decimal Floating-Point extension.
Pseudocode Operation
vD ← QuantizeDFP128(vA, vB, FPSCR[RN])
Programming Note
The dquaq instruction is used to convert and round a decimal floating-point number to a specified exponent. Ensure the operand is correctly aligned and check the FPSCR for rounding mode settings. This instruction operates at the problem state privilege level and may raise exceptions if overflow occurs or if invalid operands are provided.
Example
Encoding
Operands
-
vD
Target -
vA
Source -
vB
Reference