VSX Instructions
290 PowerISA instructions in this extension - showing 100 per page, page 2 of 3 - click any row for encoding, pseudocode, and full documentation.
| Mnemonic | Syntax | Format | Summary |
|---|---|---|---|
| xsdivqp | xsdivqp vD, vA, vB | X-form | Divides the contents of two quad-precision floating-point registers and places the result in another register. |
| xsdivqpo | xsdivqpo vD, vA, vB | X-form | Used for Quad-Precision arithmetic on hardware that splits quads. |
| xsdivsp | xsdivsp XT, XA, XB | XX3-form | Divides the contents of two doubleword elements in VSX registers and places the result in a single-precision format. |
| xsiexpdp | xsiexpdp XT, XA, XB | XX3-form | Inserts exponent from one double into another. |
| xsiexpqp | xsiexpqp VRT,VRA,VRB | X-form | Inserts the exponent from a doubleword element of one vector register into another vector register. |
| xsmaddadp | xsmaddadp XT,XA,XB | XX3-form | Performs a double-precision floating-point multiply-add operation. |
| xsmaddasp | xsmaddasp XT,XA,XB | XX3-form | Performs a single-precision floating-point multiply-add operation. |
| xsmaddmsp | xsmaddmsp FRT,FRB,FRC | XX3-form | Multiplies two single-precision floating-point values and adds a third, storing the result in the target register (Type-M form). |
| xsmaddqp | xsmaddqp VRT,VRA,VRB | X-form | Performs a quad-precision floating-point multiply-add operation with rounding to even. |
| xsmaxcdp | xsmaxcdp XT, XA, XB | XX3-form | Computes the maximum of two double-precision floating-point values and stores the result in a vector scalar register. |
| xsmaxcqp | xsmaxcqp vD, vA, vB | X-form | Compares two quad-precision floating-point values and selects the maximum. |
| xsmaxdp | xsmaxdp XT, XA, XB | XX3-form | Compares the doubleword elements of two vector scalar registers and stores the maximum value in another vector scalar register. |
| xsmaxjdp | xsmaxjdp XT, XA, XB | XX3-form | Compares two double-precision floating-point values and returns the larger one, with specific handling for zero and NaN values. |
| xsmincdp | xsmincdp XT, XA, XB | XX3-form | Computes the minimum of two double-precision floating-point numbers and handles NaNs according to Type-C rules. |
| xsmincqp | xsmincqp vD, vA, vB | X-form | Compares two quad-precision floating-point values and selects the minimum value. |
| xsmindp | xsmindp XT, XA, XB | XX3-form | Computes the minimum of two double-precision floating-point values and places the result into a vector scalar register. |
| xsminjdp | xsminjdp XT, XA, XB | XX3-form | Compares two double-precision floating-point values and selects the minimum value, handling special cases like NaNs and zeros. |
| xsmsubadp | xsmsubadp XT,XA,XB | XX3-form | Performs a double-precision floating-point multiply-subtract operation. |
| xsmsubasp | xsmsubasp XT,XA,XB | X-form | Performs a multiply-subtract-add operation on single-precision floating-point values. |
| xsmsubqp | xsmsubqp VRT,VRA,VRB | X-form | Performs a multiply-subtract operation on quad-precision floating-point values. |
| xsmsubqpo | xsmsubqpo VRT,VRA,VRB | X-form | Performs a multiply-subtract operation on quad-precision floating-point values. |
| xsmuldp | xsmuldp XT,XA,XB | XX3-form | Multiplies two double-precision floating-point numbers and places the result in a vector register. |
| xsmulqp | xsmulqp vD, vA, vB | X-form | Multiplies two quad-precision floating-point numbers and rounds the result to odd. |
| xsmulsp | xsmulsp XT, XA, XB | XX3-form | Multiplies two single-precision floating-point numbers and stores the result in a doubleword element of a VSX register. |
| xsnabsdp | xsnabsdp XT,XB | XX2-form | Computes the negative absolute value of a double-precision floating-point number. |
| xsnegdp | xsnegdp XT, XB | XX2-form | Negates the contents of a double-precision floating-point register and stores the result in another register. |
| xsnegqp | xsnegqp vD, vB | X-form | Negates a 128-bit Quad float. |
| xsnmaddadp | xsnmaddadp XT,XA,XB | XX3-form | Performs a negative multiply-add operation on double-precision floating-point values. |
| xsnmaddasp | xsnmaddasp XT,XA,XB | XX3-form | Performs a negative multiply-add operation on single-precision floating-point values. |
| xsnmaddmdp | xsnmaddmdp VRT, VRA, VRB, VRC | XX3-form | Computes the negative of the fused multiply-add of the double-precision floating-point operands, storing the result in the target scalar VSX register (Type-M: target register is used as the addend). |
| xsnmaddqp | xsnmaddqp VRT,VRA,VRB | X-form | Performs a negative multiply-add operation on quad-precision floating-point values. |
| xsnmaddqpo | xsnmaddqpo VRT,VRA,VRB | X-form | Performs a negative multiply-add operation on quad-precision floating-point values. |
| xsnmsubadp | xsnmsubadp XT,XA,XB | XX3-form | Performs a negative multiply-subtract operation on double-precision floating-point values. |
| xsnmsubasp | xsnmsubasp XT,XA,XB | XX3-form | Performs a negative multiply-subtract operation on single-precision floating-point values. |
| xsnmsubmsp | xsnmsubmsp XT,XA,XB | XX3-form | Performs a scalar negative multiply-subtract operation in single-precision floating-point, storing the result using the Type-M (multiplicand) form where the target register provides one of the multiplicand operands. |
| xsnmsubqp | xsnmsubqp VRT,VRA,VRB | X-form | Performs a negative multiply-subtract operation on quad-precision floating-point values. |
| xsrdpi | xsrdpi VRT, VRA | X-form | Rounds a double-precision floating-point value to an integer using the specified rounding mode. |
| xsrdpic | xsrdpic XT,XB | XX2-form | Rounds a double-precision floating-point value to an integer using the current rounding mode. |
| xsrdpim | xsrdpim XT,XB | XX2-form | Rounds a double-precision floating-point value in VSR[XB] towards negative infinity and places the result into VSR[XT]. |
| xsrdpip | xsrdpip XT,XB | XX2-form | Rounds a double-precision floating-point value towards positive infinity and stores the result in a vector scalar register. |
| xsrdpiz | xsrdpiz XT,XB | XX2-form | Rounds a double-precision floating-point value toward zero and places the result into a vector-scalar register. |
| xsredp | xsredp XT,XB | XX2-form | Estimates the reciprocal of a double-precision floating-point value. |
| xsresp | xsresp XT,XB | XX2-form | Estimates the reciprocal of a single-precision floating-point value. |
| xsrintqp | xsrintqp vD, vB | X-form | Rounds Quad float to nearest Integer. |
| xsrqpi | xsrqpi vD, vB, R | Z23-form | Rounds a quad-precision floating-point value in VRB to an integer and places the result in VRT. |
| xsrqpix | xsrqpix vD, vB, R | Z23-form | Rounds a Quad float to a Quad integer (Exact). |
| xsrqpxp | xsrqpxp R, VRT, VRB, RMC | Z23-form | Rounds a quad-precision floating-point value to extended-precision. |
| xsrsp | xsrsp XT,XB | X-form | Rounds a double-precision floating-point value in VSR[XB] to single-precision and stores the result in VSR[XT]. |
| xsrsqrtedp | xsrsqrtedp XT,XB | XX2-form | Estimates the reciprocal square root of a double-precision floating-point value. |
| xsrsqrtesp | xsrsqrtesp XT,XB | XX2-form | Estimates the reciprocal square root of a single-precision floating-point value. |
| xssqrtdp | xssqrtdp XT, XB | XX2-form | Computes the unbounded-precision square root of a double-precision floating-point value and rounds it to double-precision format. |
| xssqrtqp | xssqrtqp vD, vB | X-form | Computes the square root of a quad-precision floating-point value with unbounded significand precision and exponent range. |
| xssqrtqpo | xssqrtqpo vD, vB | X-form | Used for Quad-Precision arithmetic on hardware that splits quads. |
| xssqrtsp | xssqrtsp XT,XB | XX2-form | Computes the square root of a single-precision floating-point number in VSX. |
| xssubdp | xssubdp XT,XA,XB | XX3-form | Subtracts the contents of two double-precision floating-point registers and places the result in another register. |
| xssubqp | xssubqp VRT,VRA,VRB | X-form | Subtracts the contents of two quad-precision floating-point registers and handles special cases like NaNs. |
| xssubqpo | xssubqpo VRT,VRA,VRB | X-form | Used for Quad-Precision arithmetic on hardware that splits quads. |
| xssubsp | xssubsp XT, XA, XB | XX3-form | Subtracts the contents of two single-precision floating-point values and places the result in a vector register. |
| xstdivdp | xstdivdp BF,XA,XB | XX3-form | Performs a double-precision floating-point division and sets condition flags based on the result. |
| xstsqrtdp | xstsqrtdp BF,XB | XX2-form | Tests the double-precision floating-point value in VSR[XB] and sets condition register field BF based on various flags. |
| xststdcdp | xststdcdp BF, XB, DCM | XX2-form | Tests the data class of a double-precision floating-point value in VSR[XB] and sets bits in CR field BF and FPCC accordingly. |
| xststdcqp | xststdcqp BF, vB, DCM | X-form | Tests the data class of a quad-precision floating-point value and sets condition register bits based on the result. |
| xststdcsp | xststdcsp BF, vB, DCM | XX2-form | Tests the data class of a single-precision floating-point value in a VSX register and sets condition bits accordingly. |
| xsxexpdp | xsxexpdp XT, XB | XX2-form | Extracts the exponent from a double-precision floating-point value in VSR and places it into GPR. |
| xsxsigdp | xsxsigdp XT, XB | XX2-form | Extracts the significand of a double-precision floating-point value from a VSX register and places it into a general-purpose register. |
| xvabsdp | xvabsdp XT, XB | XX2-form | Computes the absolute value of each double-precision floating-point element in a vector. |
| xvabssp | xvabssp XT, XB | XX2-form | Computes absolute value for four single-precision floats. |
| xvadddp | xvadddp XT, XA, XB | XX3-form | Adds the contents of two double-precision floating-point elements from two vector registers and places the result into a target vector register. |
| xvaddsp | xvaddsp XT, XA, XB | XX3-form | Adds the contents of two single-precision floating-point vector registers and places the result in another vector register. |
| xvcmpeqdp | xvcmpeqdp XT,XA,XB | XX3-form | Compares two double-precision floating-point values in vector registers and sets the target register based on equality. |
| xvcmpeqdp. | xvcmpeqdp. XT,XA,XB | XX3-form | Compares two double-precision floating-point values in vector registers and sets the target register based on equality. |
| xvcmpeqsp | xvcmpeqsp XT,XA,XB | XX3-form | Compares each single-precision floating-point element of two VSX registers and sets the corresponding element in the target register to all 1s if they are equal, otherwise all 0s. |
| xvcmpeqsp. | xvcmpeqsp. XT,XA,XB | XX3-form | Compares each single-precision floating-point element of two VSX registers and sets the corresponding element in the target register to all 1s if they are equal, otherwise all 0s. |
| xvcmpgedp | xvcmpgedp XT,XA,XB | XX3-form | Compares two double-precision floating-point values and sets the target vector register based on the comparison. |
| xvcmpgedp. | xvcmpgedp. XT,XA,XB | XX3-form | Compares two double-precision floating-point values and sets the target vector register based on the comparison. |
| xvcmpgesp | xvcmpgesp XT,XA,XB | XX3-form | Compares each element of two single-precision floating-point vectors and sets the target vector elements to all 1s if the corresponding source elements are greater than or equal, otherwise all 0s. |
| xvcmpgesp. | xvcmpgesp. XT,XA,XB | XX3-form | Compares each element of two single-precision floating-point vectors and sets the target vector elements to all 1s if the corresponding source elements are greater than or equal, otherwise all 0s. |
| xvcmpgtdp | xvcmpgtdp XT,XA,XB | XX3-form | Compares two double-precision floating-point values and sets the target vector register based on the comparison. |
| xvcmpgtdp. | xvcmpgtdp. XT,XA,XB | XX3-form | Compares two double-precision floating-point values and sets the target vector register based on the comparison. |
| xvcmpgtsp | xvcmpgtsp XT,XA,XB | XX3-form | Compares each single-precision floating-point element in two vector registers and sets the corresponding element in a target vector register to all 1s if the first element is greater than the second, otherwise all 0s. |
| xvcmpgtsp. | xvcmpgtsp. XT,XA,XB | XX3-form | Compares each single-precision floating-point element in two vector registers and sets the corresponding element in a target vector register to all 1s if the first element is greater than the second, otherwise all 0s. |
| xvcpsgndp | xvcpsgndp XT,XA,XB | XX3-form | Copies the sign bit from one double-precision vector element to another. |
| xvcvbf16spn | xvcvbf16spn XT,XB | XX2-form | Converts a vector of bfloat16 values to single-precision floating-point format. |
| xvcvdpsp | xvcvdpsp XT, XB | XX2-form | Converts double-precision floating-point values in a vector to single-precision format. |
| xvcvdpsxds | xvcvdpsxds XT, XB | XX2-form | Converts a double-precision floating-point value to a signed doubleword integer, rounding according to the current rounding mode. |
| xvcvdpsxws | xvcvdpsxws XT,XB | X-form | Converts double-precision floating-point values in a vector to signed 32-bit integers with rounding towards zero. |
| xvcvdpuxds | xvcvdpuxds XT, XB | XX2-form | Converts double-precision floating-point values in a vector to unsigned doublewords using round towards zero. |
| xvcvdpuxws | xvcvdpuxws XT,XB | XX2-form | Converts double-precision floating-point values in a vector to unsigned 32-bit integers with rounding towards zero. |
| xvcvhpsp | xvcvhpsp XT, XB | XX2-form | Converts half-precision floating-point values in a vector register to single-precision floating-point values. |
| xvcvspbf16 | xvcvspbf16 XT,XB | XX2-form | Converts single-precision floating-point values in a vector register to bfloat16 format and stores them in another vector register. |
| xvcvspdp | xvcvspdp XT, XB | XX2-form | Converts two floats to two doubles. |
| xvcvsphp | xvcvsphp XT, XB | XX2-form | Converts each single-precision floating-point value in a vector register to half-precision and stores the result in another vector register. |
| xvcvspsxds | xvcvspsxds XT, XB | XX2-form | Converts single-precision floating-point values in a vector to signed doublewords, rounding towards zero. |
| xvcvspsxws | xvcvspsxws XT,XB | XX2-form | Converts a vector of single-precision floating-point numbers to signed integers using round towards zero. |
| xvcvspuxds | xvcvspuxds XT,XB | XX2-form | Converts a single-precision floating-point value to an unsigned doubleword integer, rounding according to the current rounding mode. |
| xvcvspuxws | xvcvspuxws XT,XB | XX2-form | Converts a single-precision floating-point value to an unsigned word using round towards zero. |
| xvcvsxddp | xvcvsxddp XT,XB | XX2-form | Converts signed doublewords from a vector register to double-precision floating-point values and rounds them. |
| xvcvsxdsp | xvcvsxdsp XT,XB | XX2-form | Converts signed doubleword elements of a vector register to single-precision floating-point and rounds the result. |
| xvcvsxwdp | xvcvsxwdp XT,XB | XX2-form | Converts signed word elements from a vector register to double-precision floating-point elements in another vector register. |
| xvcvsxwsp | xvcvsxwsp XT, XB | XX2-form | Converts a signed integer in each word of the source vector to single-precision floating-point and rounds it. |