xscvdphp
VSX Scalar Convert Double to Half-Precision
Converts a double-precision floating-point value to a half-precision floating-point value with rounding.
Details
Converts the double-precision floating-point value in XB to a half-precision floating-point value, placing the result in the lower half of XT. The conversion applies rounding according to the current floating-point rounding mode in FPSCR. Requires VSX support.
Pseudocode Operation
XT ← convert_to_half_precision(XB, round_mode=FPSCR[RN])
Programming Note
This instruction can be used to operate on a single-precision source operand. 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 -
XB
Source