dcmpoq
Decimal Compare Ordered Quad-Precision
Compares two DFP values and sets the condition register based on their order.
Details
The dcmpoq instruction compares two decimal floating-point operands in quad-precision format. It sets the designated CR field to indicate the result of the comparison and updates the FPCC field accordingly.
Pseudocode Operation
if (RA < RB) then
CR0 <- LT
else if (RA > RB) then
CR0 <- GT
else
CR0 <- EQ
Programming Note
The dcmpoq instruction is used to compare two quad-precision decimal floating-point numbers. It sets the CR0 register field to indicate whether the first operand is less than, greater than, or equal to the second operand. Ensure that operands are properly aligned and that the FPSCR (Floating Point Status and Control Register) is correctly configured for accurate comparison results.
Example
Encoding
Operands
-
BF
CR Field -
vA
Src A -
vB
Src B -
RT
Target General Purpose Register -
RA
Source General Purpose Register -
RB
Source General Purpose Register