 RealView Compiler User's Guide |
|
| TI C55x intrinsics3.1.4. TI C55x intrinsicsThe Texas Instruments (TI) C55x compiler recognizes a number of intrinsics for the optimization of C code. RVCT supports the emulation of selected TI C55x intrinsics through the header file, c55x.h. TI C55x intrinsics that are emulated in c55x.h include: Intrinsics for addition, subtraction, negation and absolute value, such as _sadd and _ssub. For example, _sadd(v1, v2) returns the 16‑bit saturated sum of v1 and v2. Intrinsics for multiplication and shifting, such as _smpy and _sshl. For example, _smpy(v1, v2) returns the saturated fractional‑mode product of v1 and v2. Intrinsics for rounding, saturation, bitcount and extremum, such as _round and _count. For example, _round(v1) returns the value v1 rounded by adding 215 using unsaturated arithmetic, clearing the lower 16 bits.
The following TI C55x intrinsics are not supported in c55x.h: Associative variants of intrinsics for addition and multiply‑and‑accumulate. This includes all TI C55x intrinsics prefixed with _a_, for example, _a_sadd and _a_smac. Rounding variants of intrinsics for multiplication and shifting, for example, _smacr and _smasr. All long long variants of intrinsics. This includes all TI C55x intrinsics prefixed with _ll, for example, _llsadd and _llshl. long long variants of intrinsics are not supported in RVCT because they operate on 40-bit data. All arithmetic intrinsics with side effects. For example, the TI C55x intrinsics _firs and _lms are not defined in c55x.h. Intrinsics for ETSI support functions, such as L_add_c and L_sub_c. NoteAn exception is the ETSI support function for saturating division, divs. This intrinsic is supported in c55x.h.
See the header file c55x.h for a complete list of the TI C55x intrinsics emulated in RVCT. For more information on TI compiler intrinsics see http://www.ti.com. |
|