vprtybd
Vector Parity Byte Doubleword
Computes parity of bytes within doublewords.
Details
The Vector Parity Byte Doubleword instruction calculates the parity of the least significant bit (LSB) in each byte of a doubleword element. For each integer value i from 0 to 1, it checks if the sum of the LSBs in each byte sub-element of doubleword element i of VSR[VRB+32] is odd. If the sum is odd, it places the value 1 into doubleword element i of VSR[VRT+32]; otherwise, it places the value 0.
Pseudocode Operation
Programming Note
This instruction is useful for calculating the parity of the least significant bit in each byte of a doubleword element. Ensure that the Vector Facility (MSR.VEC) is enabled before using this instruction; otherwise, it will raise an exception. The operation is performed on 64-bit elements, and the result is stored in the corresponding output vector register. There are no specific alignment requirements for the input data.
Example
Encoding
Operands
-
vD
Target -
vB
Source