vsum4sbs
Vector Sum-across Partial (1/4) Signed Byte Saturate
Adds the contents of four signed byte elements from two vector registers and saturates the result.
Details
For vsum4sbs, the sum of the signed integer values in the four byte elements contained in word element i of VSR[VRA+32] is added to the signed integer value in word element i of VSR[VRB+32]. If the intermediate result is greater than 2^31-1 or less than -2^31, the result saturates and SAT is set to 1.
Pseudocode Operation
Programming Note
vsum4sbs is useful for accumulating sums of byte elements within words, with saturation handling. Ensure vectors are properly aligned and check VSCR.SAT after execution to handle overflow cases. This instruction operates at the user privilege level.
Example
Encoding
Operands
-
vD
Target -
vA
Src A -
vB
Accumulator -
VRT
Target Vector Register -
VRA
Source Vector Register -
VRB
Source Vector Register