Sie sind auf Seite 1von 5

Word16 Returns short absolute value of a 16-bit

abs_s(Word16 argument.
var1)
Word16 Performs short add of var1 and var2,
add(Word16 var1, with overflow control and saturation. If
Word16 var2)
overflow occurs, 16-bit result is +32767;
if underflow occurs, 16-bit result is -
32768.
Word32 Adds 32-bit arguments.
add2(Word32 var1,
Word32
var2);
Word16 Performs short divide: fractional integer
div_s(Word16 division of var1 by var2. Both
var1,
Word16 arguments must be positive; var2 must
var2); not exceed var1. Result is positive
(leading bit = 0), truncated to 16 bits.
Word16 Returns most significant 16 bits of 32-
extract_h(Word32 bit argument.
L_var1);
Word16 Returns least significant 16 bits of 32-bit
extract_l(Word32 L_var1); argument.
Word32 Performs multiply accumulate: multiplies var1
L_mac(Word32 L_var3, by var2 and shifts result left by 1. Adds 32-bit
Word16 var1,
Word16 var2); result to L_var3 with saturation, returning 32-
bit result.
Word32 Performs multiply subtract: multiplies var1 by
L_msu(Word32 L_var3, var2 and shifts result left by 1. Subtracts 32-bit
Word16 var1,
Word16 var2); result from L_var3 with saturation, returning
32-bit result.
Word16 Performs multiply, accumulate, and round:
mac_r(Word32 L_var3, multiplies var1 by var2 and shifts result left by
Word16 var1,
Word16 var2); 1. Adds 32-bit result to L_var3 with saturation.
Rounds the result's least significant 16 bits into
the most significant 16 bits with saturation,
then shifts the result right by 16. Returns 16-bit
result.
Word16 Returns the greater of two 16-bit fractional
max(Word16 var1, arguments.
Word16 var2);
Word32 Returns the greater of two 32-bit fractional
max2(Word32 var1, arguments.
Word32 var2);
Word16 Returns the greater of two 16-bit fractional
maxm(Word16 var1, arguments.
Word16 var2);
Word16 Returns the lesser of two 16-bit fractional
min(Word16 var1, arguments.
Word16 var2);
Word32 Returns the lesser of two 32-bit fractional
min2(Word32 var1, arguments.
Word32 var2);
Word16 Performs multiply, subtract, and round:
msu_r(Word32 L_var3, multiplies var1 by var2 and shifts result left by
Word16 var1,
Word16 var2); 1. Subtracts 32-bit result from L_var3 with
saturation. Rounds the result's least significant
16 bits into the most significant 16 bits with
saturation, then shifts the result right by 16.
Returns 16-bit result.
Word16 Performs short multiply of var1 by var2, giving
mult(Word16 var1, scaled, 16-bit result.
Word16 var2);
Word16 With addition or subtraction, prevents creation
mult_nomac(Word16 var1, of atomic Mac sequences. Useful if saturation
Word16 var2);
of atomic operation and sequence saturation
are not equivalent.
Word16 Performs short multiply, with rounding.
mult_r(Word16 var1,
Word16 var2);
Word16 Negates var1 with saturation.
negate(Word16 var1);
Word16 Normalizes 16-bit fractional argument: shifts
norm_s(Word16 var1); left enough times to normalize a positive var1
(interval 16384 - 32767), or to normalize a
negative var 1 (interval -32768 - -16384).
Word16 Normalizes negatively: multiplies result of
neg_norm_s(Word16 var1);
norm_s by -1.
Word16 Rounds least significant 16 bits of L_var1 into
round(Word32 L_var1); most significant 16 bits, with saturation. Shifts
resulting bits right by 16, returning 16-bit
result.
Word16 Limits 32-bit argument to the range of a 16-bit
saturate(Word32 L_var1); word.
Word16 Performs short shift left: arithmetically shifts
shl(Word16 var1, var1 left var2 positions, zero-filling the var2
Word16 var2);
least significant positions of the result. If var2
is negative, arithmetically shifts var1 right by
var2 with sign extension. Saturates result in
case of underflow or overflow.
Word16 Performs short shift left without saturation.
shl_nosat(Word16 var1,
Like shl, but does not saturate result in case of
Word16 var2);
underflow or overflow.
Word16 Performs short shift right: arithmetically shifts
shr(Word16 var1, var1 right var2 positions with sign extension. If
Word16 var2);
var2 is negative, arithmetically shifts var1 left
by var2 with sign extension. Saturates the
result in case of underflow or overflow.
Word16 Performs short shift right without saturation.
shr_nosat(Word16 var1,
Like shr, but does not saturate result in case of
Word16 var2);
underflow or overflow.
Word16 Performs short shift right with rounding. Like
shr_r(Word16 var1,
shr, but with rounded result.
Word16 var2);
Word16 Performs short subtract of var2 from var1, with
sub(Word16 var1, overflow control and saturation. If overflow
Word16 var2);
occurs, 16-bit result is +32767; if underflow
occurs, 16-bit result is -32768.
Word32 Subtracts 32-bit var2 value from 32-bit var1
sub2(Word32 var1, value.
Word32 var2);

Long Fractional Word32 Performs iterative fractional division of destination operand by


Arithmetic div_iter(Word32 var1, source operand; stores result in destination operand. Matches
Word16
Primitives var2); StarCore div instruction.
Word32 Extracts a bit field from a 32-bit signed long fractional; express
Extract(Word32 val, mask as an unsigned 32-bit long fractional. Matches StarCore
UWord32
Mask); extract instruction.
Word32 Extracts a bit field from a 32-bit unsigned long fractional; express
ExtractU(UWord32 val, mask as an unsigned 32-bit long fractional. Matches StarCore
UWord32
Mask); extractu instruction.
Word32 Returns long absolute value of a 32-bit argument; saturates if
L_abs(Word32 L_var1); value is -214783648.
Word32 Performs long add of L_var1 and L_var2, with overflow control
L_add(Word32 L_var1, and saturation. If overflow occurs, result is +2147483647; if
Word32 L_var2);
underflow occurs, result is
-2147483648.
Word32 Deposits short in most significant bits: copies values of var1 16
L_deposit_h(Word16 bits into most significant 16 bits of 32-bit return value; zeros out
var1);
the 16 least significant bits of the return value.
Word32 Deposits short in least significant bits: copies values of var116
L_deposit_l(Word16 bits into least significant 16 bits of 32-bit return value; sign-
var1);
extends 16 most significant bits of the return vbalue.
Word32 Returns the greater of two 32-bit fractional arguments.
L_max(Word32 L_var1,
Word32 L_var2);
Word32 Returns the greater of two 32-bit fractional arguments.
L_maxm(Word32 L_var1,
Word32
L_var2);
Word32 Returns the lesser of two 32-bit fractional values.
L_min(Word32 L_var1,
Word32 L_var2);
Word32 Performs long multiply of var1 by var2, with one shift left, giving
L_mult(Word16 var1, 32-bit result.
Word16 var2);
Word32 With addition or subtraction, prevents creation of atomic Mac
L_mult_nomac(Word16 sequences. Useful if saturation of atomic operation and sequence
var1,
Word16 saturation are not equivalent.
var2);
Word32 Performs long negate: negates 32-bit L_var1. Saturates if value is
L_negate(Word32 -2147483648 (0x80000000).
L_var1);
Word32 Saturates a 32-bit value.
L_sat(Word32 L_var1);
Word32 Performs long shift left: arithmetically shifts L_var1 left var2
L_shl(Word32 L_var1, positions, zero-filling the var2 least significant positions of the
Word16 var2);
result. If var2 is negative, arithmetically shifts L_var1 right by
var2 with sign extension. Saturates result in case of underflow or
overflow.
Word32 Performs long shift left without saturation. Like L_shl, but does
L_shl_nosat(Word32
not saturate result in case of underflow or overflow.
L_var1,
Word16
var2);
Word32 Performs long shift right: arithmetically shifts L_var1 right var2
L_shr(Word32 L_var1, positions with sign extension. If var2 is negative, arithmetically
Word16 var2);
shifts L_var1 left by var2 and zero fills result's var2 lest
significant bits. Saturates the result in case of underflow or
overflow.
Word32 Performs long shift right without saturation. Like L_shr, but does
L_shr_nosat(Word32
not saturate result in case of underflow or overflow.
L_var1,
Word16
var2);
Word32 Performs long shifr right with rounding. Like L_shr, but with
L_shr_r(Word32
rounded result.
L_var1,
Word16 var2)
Word32 Performs long subtraction of L_var2 from L_var1, with overflow
L_sub(Word32 L_var1, control and saturation. If overflow occurs, 32-bit result is
Word32 L_var2);
+2147483647; if underflow occurs, 32-bit result is
-2147483648
Word16 Returns
norm_l(Word32 -1( norm_l() )
L_var1);
Word16 Normalizes 32-bit fractional argument: shifts left enough times to
norm_l(Word32 normalize a positive L_var1 (interval 1073741824 -
L_var1);
2147483647), or to normalize a negative L_var 1 (interval -
2147483648 - -1073741824).
Word64 Returns 64-bit value to which the passed-in pointer Word64
Read_64(Word64 * points.
Fifo);
void Writes input 64-bit value to the location that the passed-in pointer
Write_64(Word64 * Word64 specifies.
Fifo,
Word64
Value);

Das könnte Ihnen auch gefallen