Vector/SIMD Multimedia Extension intrinsics are grouped into three classes.
These classes are:
The Vector/SIMD Multimedia Extension intrinsics and predicates use the prefix vec_ in front of an assembly-language or operation mnemonic; predicate intrinsics use the prefixes vec_all and vec_any. When compiled, the intrinsics generate one or more Vector/SIMD Multimedia Extension assembly-language instructions.
The specific and generic intrinsics are shown in Table 1. The predicate intrinsics are shown in Table 2.
Intrinsic | Description |
---|---|
Arithmetic Intrinsics | |
d = vec_abs(a) | Vector Absolute Value |
d = vec_abss(a) | Vector Absolute Value Saturated |
d = vec_add(a,b) | Vector Add |
d = vec_addc(a,b) | Vector Add Carryout Unsigned Word |
d = vec_adds(a,b) | Vector Add Saturated |
d = vec_avg(a,b) | Vector Average |
d = vec_madd(a,b,c) | Vector Multiply Add |
d = vec_madds(a,b,c) | Vector Multiply Add Saturated |
d = vec_max(a,b) | Vector Maximum |
d = vec_min(a,b) | Vector Minimum |
d = vec_mladd(a,b,c) | Vector Multiply Low and Add Unsigned Half Word |
d = vec_mradds(a,b,c) | Vector Multiply Round and Add Saturated |
d = vec_msum(a,b,c) | Vector Multiply Sum |
d = vec_msums(a,b,c) | Vector Multiply Sum Saturated |
d = vec_mule(a,b) | Vector Multiply Even |
d = vec_mulo(a,b) | Vector Multiply Odd |
d = vec_nmsub(a,b,c) | Vector Negative Multiply Subtract |
d = vec_sub(a,b) | Vector Subtract |
d = vec_subc(a,b) | Vector Subtract Carryout |
d = vec_subs(a,b) | Vector Subtract Saturated |
d = vec_sum4s(a,b) | Vector Sum Across Partial (1/4) Saturated |
d = vec_sum2s(a,b) | Vector Sum Across Partial (1/2) Saturated |
d = vec_sums(a,b) | Vector Sum Saturated |
Rounding And Conversion Intrinsics | |
d = vec_ceil(a) | Vector Ceiling |
d = vec_ctf(a,b) | Vector Convert from Fixed-Point Word |
d = vec_cts(a,b) | Vector Convert to Signed Fixed-Point Word Saturated |
d = vec_ctu(a,b) | Vector Convert to Unsigned Fixed-Point Word Saturated |
d = vec_floor(a) | Vector Floor |
d = vec_trunc(a) | Vector Truncate |
Floating-Point Estimate Intrinsics | |
d = vec_expte(a) | Vector Is 2 Raised to the Exponent Estimate Floating-Point |
d = vec_loge(a) | Vector Log2 Estimate Floating-Point |
d = vec_re(a) | Vector Reciprocal Estimate |
d = vec_rsqrte(a) | Vector Reciprocal Square Root Estimate |
Compare Intrinsics | |
d = vec_cmpb(a,b) | Vector Compare Bounds Floating-Point |
d = vec_cmpeq(a,b) | Vector Compare Equal |
d = vec_cmpge(a,b) | Vector Compare Greater Than or Equal |
d = vec_cmpgt(a,b) | Vector Compare Greater Than |
d = vec_cmple(a,b) | Vector Compare Less Than or Equal |
d = vec_cmplt(a,b) | Vector Compare Less Than |
Logical Intrinsics | |
d = vec_and(a,b) | Vector Logical AND |
d = vec_andc(a,b) | Vector Logical AND with Complement |
d = vec_nor(a,b) | Vector Logical NOR |
d = vec_or(a,b) | Vector Logical OR |
d = vec_xor(a,b) | Vector Logical XOR |
Rotate and Shift Intrinsics | |
d = vec_rl(a,b) | Vector Rotate Left |
d = vec_round(a) | Vector Round |
d = vec_sl(a,b) | Vector Shift Left |
d = vec_sld(a,b,c) | Vector Shift Left Double |
d = vec_sll(a,b) | Vector Shift Left Long |
d = vec_slo(a,b) | Vector Shift Left by Octet |
d = vec_sr(a,b) | Vector Shift Right |
d = vec_sra(a,b) | Vector Shift Right Algebraic |
d = vec_srl(a,b) | Vector Shift Right Long |
d = vec_sro(a,b) | Vector Shift Right by Octet |
Load and Store Intrinsics | |
d = vec_ld(a,b) | Vector Load Indexed |
d = vec_lde(a,b) | Vector Load Element Indexed |
d = vec_ldl(a,b) | Vector Load Indexed LRU |
d = vec_lvlx(a,b) | Load Vector Left Indexed |
d = vec_lvlxl(a,b) | Load Vector Left Indexed Last |
d = vec_lvrx(a,b) | Load Vector Right Indexed |
d = vec_lvrxl(a,b) | Load Vector Right Indexed Last |
d = vec_lvsl(a,b) | Vector Load for Shift Left |
d = vec_lvsr(a,b) | Vector Load Shift Right |
d = vec_stvlx(a,b) | Store Vector Left Indexed |
d = vec_stvlxl(a,b) | Store Vector Left Indexed Last |
d = vec_stvrx(a,b) | Store Vector Right Indexed |
d = vec_stvrxl(a,b) | Store Vector Right Indexed Last |
vec_st(a,b,c) | Vector Store Indexed |
vec_ste(a,b,c) | Vector Store Element Indexed |
vec_stl(a,b,c) | Vector Store Indexed LRU |
Pack and Unpack Intrinsics | |
d = vec_pack(a,b) | Vector Pack |
d = vec_packpx(a,b) | Vector Pack Pixel |
d = vec_packs(a,b) | Vector Pack Saturated |
d = vec_packsu(a,b) | Vector Pack Saturated Unsigned |
d = vec_unpackh(a) | Vector Unpack High Element |
d = vec_unpackl(a) | Vector Unpack Low Element |
Merge Intrinsics | |
d = vec_mergeh(a,b) | Vector Merge High |
d = vec_mergel(a,b) | Vector Merge Low |
Permute and Select Intrinsics | |
d = vec_perm(a,b,c) | Vector Permute |
d = vec_sel(a,b,c) | Vector Select |
Stream Intrinsics | |
vec_dss(a) | Vector Data Stream Stop |
vec_dssall() | Vector Stream Stop All |
vec_dst(a,b,c) | Vector Data Stream Touch |
vec_dstst(a,b,c) | Vector Data Stream Touch for Store |
vec_dststt(a,b,c) | Vector Data Stream Touch for Store Transient |
vec_dstt(a,b,c) | Vector Data Stream Touch Transient |
Move Intrinsics | |
d = vec_mfvscr | Vector Move from Vector Status and Control Register |
vec_mtvscr(a) | Vector Move to Vector Status and Control Register |
Replicate Intrinsics | |
d = vec_splat(a,b) | Vector Splat |
d = vec_splat_s8(a) | Vector Splat Signed Byte |
d = vec_splat_s16(a) | Vector Splat Signed Half-Word |
d = vec_splat_s32(a) | Vector Splat Signed Word |
d = vec_splat_u8(a) | Vector Splat Unsigned Byte |
d = vec_splat_u16(a) | Vector Splat Unsigned Half-Word |
d = vec_splat_u32(a) | Vector Splat Unsigned Word |
Scalar Intrinsics | |
d = vec_extract(a,element) | Extract Vector Element from Vector |
d = vec_insert(a,b,element) | Insert Scalar into Specified Vector Element |
d = vec_promote(a,element) | Promote Scalar to a Vector |
d = vec_splats(a) | Splat Scalar to Vector |
Predicate | Description |
---|---|
All Predicates | |
d = vec_all_eq(a,b) | All Elements Equal |
d = vec_all_ge(a,b) | All Elements Greater Than or Equal |
d = vec_all_gt(a,b) | All Elements Greater Than |
d = vec_all_in(a,b) | All Elements in Bounds |
d = vec_all_le(a,b) | All Elements Less Than or Equal |
d = vec_all_lt(a,b) | All Elements Less Than |
d = vec_all_nan(a) | All Elements Not a Number |
d = vec_all_ne(a,b) | All Elements Not Equal |
d = vec_all_nge(a,b) | All Elements Not Greater Than or Equal |
d = vec_all_ngt(a,b) | All Elements Not Greater Than |
d = vec_all_nle(a,b) | All Elements Not Less Than or Equal |
d = vec_all_nlt(a,b) | All Elements Not Less Than |
d = vec_all_numeric(a) | All Elements Numeric |
Any Predicates | |
d = vec_any_eq(a,b) | Any Element Equal |
d = vec_any_ge(a,b) | Any Element Greater Than or Equal |
d = vec_any_gt(a,b) | Any Element Greater Than |
d = vec_any_le(a,b) | Any Element Less Than or Equal |
d = vec_any_lt(a,b) | Any Element Less Than |
d = vec_any_nan(a) | Any Element Not a Number |
d = vec_any_ne(a,b) | Any Element Not Equal |
d = vec_any_nge(a,b) | Any Element Not Greater Than or Equal |
d = vec_any_ngt(a,b) | Any Element Not Greater Than |
d = vec_any_nle(a,b) | Any Element Not Less Than or Equal |
d = vec_any_nlt(a,b) | Any Element Not Less Than |
d = vec_any_numeric(a) | Any Element Numeric |
d = vec_any_out(a,b) | Any Element Out of Bounds |