xsmincdp
VSX Scalar Minimum Type-C Double-Precision
Computes the minimum of two double-precision floating-point numbers and handles NaNs according to Type-C rules.
Details
If either src1 or src2 is a NaN, result is src2. Otherwise, if src1 is less than src2, result is src1. Otherwise, result is src2. The contents of doubleword 0 of VSR[XT] are set to the value result. The contents of doubleword 1 of VSR[XT] are set to 0.
Pseudocode Operation
Programming Note
xsmincdp can be used to implement the C/C++/Java conditional operator (x<y)?x:y for single-precision and double-precision arguments. Previous versions of the architecture allowed the contents of doubleword 1 of the result register to be undefined. However, all processors that support this instruction write 0s into doubleword 1 of the result register, as is required by this version of the architecture.
Example
Encoding
Operands
-
XT
Target -
XA
Src A -
XB
Src B