modsq
Modulo Signed Quadword
modsq vD, vA, vB
Computes remainder of 128-bit signed division.
Details
Computes the remainder of a 128-bit signed integer division, storing the 128-bit signed remainder in vD. This is a VSX or MMA category instruction. The operation uses the dividend (vA) and divisor (vB) to compute the modulo result, with sign following the dividend.
Pseudocode Operation
vD ← vA mod vB (128-bit signed integer modulo)
Example
modsq vd, va, vb
Encoding
Binary Layout
4
0
vD
6
vA
11
vB
16
267
21
Operands
-
vD
Target -
vA
Dividend -
vB
Divisor