vmulouh

Vector Multiply Odd Unsigned Halfword

vmulouh vD, vA, vB

Multiplies odd unsigned halfwords to words.

Details

The Vector Multiply Odd Unsigned Halfword instruction multiplies the unsigned integer values from odd-numbered halfwords of two source vectors and stores the 32-bit products in corresponding word elements of a destination vector.

Pseudocode Operation

if MSR.VEC=0 then Vector_Unavailable()
do i = 0 to 3
   src1 ←EXTZ(VSR[VRA+32].hword[2×i+1])
   src2 ←EXTZ(VSR[VRB+32].hword[2×i+1])
   VSR[VRT+32].word[i] ←CHOP32(src1 × src2)
end

Programming Note

This instruction is useful for performing element-wise multiplication of unsigned halfwords from two vectors. Ensure that the Vector Facility (MSR.VEC) is enabled before using this instruction; otherwise, a Vector_Unavailable exception will be raised. The operation targets odd-numbered halfwords, so developers should align their data accordingly to achieve the desired results.

Example

vmulouh vd, va, vb

Encoding

Binary Layout
4
0
vD
6
vA
11
vB
16
72
21
 
Format VX-form
Opcode 0x10000048
Extension VMX (AltiVec)
Registers Altered MSR

Operands

  • vD
    Target
  • vA
    Src A
  • vB
    Src B