Compute Library  18.03
fixed_point.h File Reference

Go to the source code of this file.

Macros

#define TYPE_ALIAS(type, alias)
 
#define qs8_MIN   ((char)CHAR_MIN)
 
#define qs8_MAX   ((char)CHAR_MAX)
 
#define qs16_MIN   ((short)SHRT_MIN)
 
#define qs16_MAX   ((short)SHRT_MAX)
 
#define qs32_MIN   ((int)INT_MIN)
 
#define qs32_MAX   ((int)INT_MAX)
 
#define qu8_MIN   ((uchar)0)
 
#define qu8_MAX   ((uchar)UCHAR_MAX)
 
#define qu16_MIN   ((ushort)0)
 
#define qu16_MAX   ((ushort)USHRT_MAX)
 
#define qu32_MIN   ((uint)0)
 
#define qu32_MAX   ((uint)UINT_MAX)
 
#define qs8_TYPE   char
 
#define qs8x1_TYPE   char
 
#define qs8x2_TYPE   char2
 
#define qs8x3_TYPE   char3
 
#define qs8x4_TYPE   char4
 
#define qs8x8_TYPE   char8
 
#define qs8x16_TYPE   char16
 
#define qs16_TYPE   short
 
#define qs16x1_TYPE   short
 
#define qs16x2_TYPE   short2
 
#define qs16x3_TYPE   short3
 
#define qs16x4_TYPE   short4
 
#define qs16x8_TYPE   short8
 
#define qs16x16_TYPE   short16
 
#define qs32_TYPE   int
 
#define qs32x1_TYPE   int
 
#define qs32x2_TYPE   int2
 
#define qs32x3_TYPE   int3
 
#define qs32x4_TYPE   int4
 
#define qs32x8_TYPE   int8
 
#define qs32x16_TYPE   int16
 
#define qs8_SHIFT   8
 
#define qs16_SHIFT   0
 
#define VEC_DATA_TYPE_STR(type, size)   type##x##size
 
#define VEC_DATA_TYPE(type, size)   VEC_DATA_TYPE_STR(type, size)
 
#define CONVERT_STR3(x, type, rtype)   (convert_##rtype((x)))
 
#define CONVERT_STR2(x, type, rtype)   CONVERT_STR3(x, type, rtype)
 
#define CONVERT_STR(x, type)   CONVERT_STR2(x, type, type##_TYPE)
 
#define CONVERT(x, type)   CONVERT_STR(x, type)
 
#define CONVERT_SAT_STR3(x, type, rtype)   (convert_##rtype##_sat((x)))
 
#define CONVERT_SAT_STR2(x, type, rtype)   CONVERT_SAT_STR3(x, type, rtype)
 
#define CONVERT_SAT_STR(x, type)   CONVERT_SAT_STR2(x, type, type##_TYPE)
 
#define CONVERT_SAT(x, type)   CONVERT_SAT_STR(x, type)
 
#define ABSQ_SAT_IMPL(type)
 Computes saturating absolute value of fixed point vector. More...
 
#define ABS_SAT_OP_EXPAND_STR(a, type, size)   abs_##type##x##size##_sat((a))
 
#define ABS_SAT_OP_EXPAND(a, type, size)   ABS_SAT_OP_EXPAND_STR(a, type, size)
 
#define MAXQ_IMPL(type)
 Computes max of fixed point types. More...
 
#define MAX_OP_EXPAND_STR(a, b, type, size)   max_##type##x##size((a), (b))
 
#define MAX_OP_EXPAND(a, b, type, size)   MAX_OP_EXPAND_STR(a, b, type, size)
 
#define ADDQ_SAT_IMPL(type)
 Computes saturated addition of fixed point types. More...
 
#define ADD_SAT_OP_EXPAND_STR(a, b, type, size)   add_sat_##type##x##size((a), (b))
 
#define ADD_SAT_OP_EXPAND(a, b, type, size)   ADD_SAT_OP_EXPAND_STR(a, b, type, size)
 
#define SUBQ_SAT_IMPL(type)
 Computes saturated subtraction of fixed point types. More...
 
#define SUB_SAT_OP_EXPAND_STR(a, b, type, size)   sub_sat_##type##x##size((a), (b))
 
#define SUB_SAT_OP_EXPAND(a, b, type, size)   SUB_SAT_OP_EXPAND_STR(a, b, type, size)
 
#define MULQ_IMPL(type, itype)
 
#define MUL_OP_EXPAND_STR(a, b, type, size, position)   mul_##type##x##size((a), (b), (position))
 
#define MUL_OP_EXPAND(a, b, type, size, position)   MUL_OP_EXPAND_STR(a, b, type, size, position)
 
#define MULQ_SAT_IMPL(type, itype)
 
#define MUL_SAT_OP_EXPAND_STR(a, b, type, size, position)   mul_sat_##type##x##size((a), (b), (position))
 
#define MUL_SAT_OP_EXPAND(a, b, type, size, position)   MUL_SAT_OP_EXPAND_STR(a, b, type, size, position)
 
#define MLAQ_SAT_IMPL(type, itype)
 Saturate multiply-accumulate. More...
 
#define MLA_SAT_OP_EXPAND_STR(a, b, c, type, size, position)   mla_sat_##type##x##size((a), (b), (c), (position))
 
#define MLA_SAT_OP_EXPAND(a, b, c, type, size, position)   MLA_SAT_OP_EXPAND_STR(a, b, c, type, size, position)
 
#define MLALQ_SAT_IMPL(type, itype)
 Saturate multiply-accumulate long. More...
 
#define MLAL_SAT_OP_EXPAND_STR(a, b, c, type, size, position)   mlal_sat_##type##x##size((a), (b), (c), (position))
 
#define MLAL_SAT_OP_EXPAND(a, b, c, type, size, position)   MLAL_SAT_OP_EXPAND_STR(a, b, c, type, size, position)
 
#define DIVQ_SAT_IMPL(stype, type, itype)
 Saturate division of two fixed point vectors. More...
 
#define DIV_SAT_OP_EXPAND_STR(a, b, type, position)   div_sat_##type((a), (b), (position))
 
#define DIV_SAT_OP_EXPAND(a, b, type, position)   DIV_SAT_OP_EXPAND_STR(a, b, type, position)
 
#define DIV_SAT_OP_VEC_EXPAND_STR(a, b, type, size, position)   div_sat_##type##x##size((a), (b), (position))
 
#define DIV_SAT_OP_VEC_EXPAND(a, b, type, size, position)   DIV_SAT_OP_VEC_EXPAND_STR(a, b, type, size, position)
 
#define EXPQ_IMPL(stype, type, size)
 Saturate exponential of a fixed point vector. More...
 
#define EXP_OP_EXPAND_STR(a, type, size, position)   exp_sat_##type##x##size((a), (position))
 
#define EXP_OP_EXPAND(a, type, size, position)   EXP_OP_EXPAND_STR(a, type, size, position)
 
#define LOGQ_IMPL(stype, type, size)
 Saturate logarithm of a fixed point vector. More...
 
#define LOG_OP_EXPAND_STR(a, type, size, position)   log_sat_##type##x##size((a), (position))
 
#define LOG_OP_EXPAND(a, type, size, position)   LOG_OP_EXPAND_STR(a, type, size, position)
 
#define INVSQRTQ_IMPL(stype, type, size)
 Saturate inverse square root of a fixed point vector. More...
 
#define INVSQRT_OP_EXPAND_STR(a, type, size, position)   invsqrt_sat_##type##x##size((a), (position))
 
#define INVSQRT_OP_EXPAND(a, type, size, position)   INVSQRT_OP_EXPAND_STR(a, type, size, position)
 
#define TANHQ_IMPL(stype, type, size)
 Saturate hyperbolic tangent of a fixed point vector. More...
 
#define TANH_OP_EXPAND_STR(a, type, size, position)   tanh_sat_##type##x##size((a), (position))
 
#define TANH_OP_EXPAND(a, type, size, position)   TANH_OP_EXPAND_STR(a, type, size, position)
 
#define floatx16   float16
 
#define float16_TYPE   float16
 
#define CONVERTQ_DOWN_IMPL(in_type, out_type)
 
#define CONVERTQ_DOWN_SAT_IMPL(in_type, out_type)
 
#define CONVERTQ_UP_IMPL(in_type, out_type)
 
#define SQCVT_SAT_IMPL(type)
 
#define SQCVT_SAT_OP_EXPAND_STR(a, type, position)   sqcvt_##type##_sat((a), (position))
 
#define SQCVT_SAT_OP_EXPAND(a, type, position)   SQCVT_SAT_OP_EXPAND_STR((a), type, position)
 

Typedefs

typedef char qs8
 
typedef char qs8x1
 
typedef char2 qs8x2
 
typedef char3 qs8x3
 
typedef char4 qs8x4
 
typedef char8 qs8x8
 
typedef char16 qs8x16
 
typedef short qs16
 
typedef short qs16x1
 
typedef short2 qs16x2
 
typedef short3 qs16x3
 
typedef short4 qs16x4
 
typedef short8 qs16x8
 
typedef short16 qs16x16
 
typedef int qs32
 
typedef int qs32x1
 
typedef int2 qs32x2
 
typedef int3 qs32x3
 
typedef int4 qs32x4
 
typedef int8 qs32x8
 
typedef int16 qs32x16
 

Functions

qs8x16 abs_qs8x16_sat (qs8x16 VopA)
 
qs16x8 abs_qs16x8_sat (qs16x8 VopA)
 
qs8x1 max_qs8x1 (qs8x1 VopA, qs8x1 VopB)
 
qs8x2 max_qs8x2 (qs8x2 VopA, qs8x2 VopB)
 
qs8x4 max_qs8x4 (qs8x4 VopA, qs8x4 VopB)
 
qs8x8 max_qs8x8 (qs8x8 VopA, qs8x8 VopB)
 
qs8x16 max_qs8x16 (qs8x16 VopA, qs8x16 VopB)
 
qs16x1 max_qs16x1 (qs16x1 VopA, qs16x1 VopB)
 
qs16x2 max_qs16x2 (qs16x2 VopA, qs16x2 VopB)
 
qs16x4 max_qs16x4 (qs16x4 VopA, qs16x4 VopB)
 
qs16x8 max_qs16x8 (qs16x8 VopA, qs16x8 VopB)
 
qs16x16 max_qs16x16 (qs16x16 VopA, qs16x16 VopB)
 
qs8x1 add_sat_qs8x1 (qs8x1 VopA, qs8x1 VopB)
 
qs8x2 add_sat_qs8x2 (qs8x2 VopA, qs8x2 VopB)
 
qs8x4 add_sat_qs8x4 (qs8x4 VopA, qs8x4 VopB)
 
qs8x8 add_sat_qs8x8 (qs8x8 VopA, qs8x8 VopB)
 
qs8x16 add_sat_qs8x16 (qs8x16 VopA, qs8x16 VopB)
 
qs16x1 add_sat_qs16x1 (qs16x1 VopA, qs16x1 VopB)
 
qs16x2 add_sat_qs16x2 (qs16x2 VopA, qs16x2 VopB)
 
qs16x4 add_sat_qs16x4 (qs16x4 VopA, qs16x4 VopB)
 
qs16x8 add_sat_qs16x8 (qs16x8 VopA, qs16x8 VopB)
 
qs16x16 add_sat_qs16x16 (qs16x16 VopA, qs16x16 VopB)
 
qs32x1 add_sat_qs32x1 (qs32x1 VopA, qs32x1 VopB)
 
qs32x2 add_sat_qs32x2 (qs32x2 VopA, qs32x2 VopB)
 
qs32x4 add_sat_qs32x4 (qs32x4 VopA, qs32x4 VopB)
 
qs32x8 add_sat_qs32x8 (qs32x8 VopA, qs32x8 VopB)
 
qs32x16 add_sat_qs32x16 (qs32x16 VopA, qs32x16 VopB)
 
qs8x1 sub_sat_qs8x1 (qs8x1 VopA, qs8x1 VopB)
 
qs8x2 sub_sat_qs8x2 (qs8x2 VopA, qs8x2 VopB)
 
qs8x4 sub_sat_qs8x4 (qs8x4 VopA, qs8x4 VopB)
 
qs8x8 sub_sat_qs8x8 (qs8x8 VopA, qs8x8 VopB)
 
qs8x16 sub_sat_qs8x16 (qs8x16 VopA, qs8x16 VopB)
 
qs16x1 sub_sat_qs16x1 (qs16x1 VopA, qs16x1 VopB)
 
qs16x2 sub_sat_qs16x2 (qs16x2 VopA, qs16x2 VopB)
 
qs16x4 sub_sat_qs16x4 (qs16x4 VopA, qs16x4 VopB)
 
qs16x8 sub_sat_qs16x8 (qs16x8 VopA, qs16x8 VopB)
 
qs16x16 sub_sat_qs16x16 (qs16x16 VopA, qs16x16 VopB)
 
qs8x8 mul_qs8x8 (qs8x8 VopA, qs8x8 VopB, int fixed_point_position)
 
qs16x8 mul_qs16x8 (qs16x8 VopA, qs16x8 VopB, int fixed_point_position)
 
qs8x16 mul_qs8x16 (qs8x16 VopA, qs8x16 VopB, int fixed_point_position)
 
qs16x16 mul_qs16x16 (qs16x16 VopA, qs16x16 VopB, int fixed_point_position)
 
qs8x1 mul_sat_qs8x1 (qs8x1 VopA, qs8x1 VopB, int fixed_point_position)
 
qs8x2 mul_sat_qs8x2 (qs8x2 VopA, qs8x2 VopB, int fixed_point_position)
 
qs8x3 mul_sat_qs8x3 (qs8x3 VopA, qs8x3 VopB, int fixed_point_position)
 
qs8x4 mul_sat_qs8x4 (qs8x4 VopA, qs8x4 VopB, int fixed_point_position)
 
qs8x8 mul_sat_qs8x8 (qs8x8 VopA, qs8x8 VopB, int fixed_point_position)
 
qs8x16 mul_sat_qs8x16 (qs8x16 VopA, qs8x16 VopB, int fixed_point_position)
 
qs16x1 mul_sat_qs16x1 (qs16x1 VopA, qs16x1 VopB, int fixed_point_position)
 
qs16x2 mul_sat_qs16x2 (qs16x2 VopA, qs16x2 VopB, int fixed_point_position)
 
qs16x3 mul_sat_qs16x3 (qs16x3 VopA, qs16x3 VopB, int fixed_point_position)
 
qs16x4 mul_sat_qs16x4 (qs16x4 VopA, qs16x4 VopB, int fixed_point_position)
 
qs16x8 mul_sat_qs16x8 (qs16x8 VopA, qs16x8 VopB, int fixed_point_position)
 
qs16x16 mul_sat_qs16x16 (qs16x16 VopA, qs16x16 VopB, int fixed_point_position)
 
qs8x8 mla_sat_qs8x8 (qs8x8 VopA, qs8x8 VopB, qs8x8 VopC, int fixed_point_position)
 
qs8x16 mla_sat_qs8x16 (qs8x16 VopA, qs8x16 VopB, qs8x16 VopC, int fixed_point_position)
 
qs16x8 mla_sat_qs16x8 (qs16x8 VopA, qs16x8 VopB, qs16x8 VopC, int fixed_point_position)
 
qs16x8 mlal_sat_qs8x8 (qs16x8 VopA, qs8x8 VopB, qs8x8 VopC, int fixed_point_position)
 
qs32x8 mlal_sat_qs16x8 (qs32x8 VopA, qs16x8 VopB, qs16x8 VopC, int fixed_point_position)
 
qs8x16 div_sat_qs8x16 (qs8x16 VopA, qs8x16 VopB, int fixed_point_position)
 
qs16x8 div_sat_qs16x8 (qs16x8 VopA, qs16x8 VopB, int fixed_point_position)
 
qs16x16 div_sat_qs16x16 (qs16x16 VopA, qs16x16 VopB, int fixed_point_position)
 
qs8 div_sat_qs8 (qs8 VopA, qs8 VopB, int fixed_point_position)
 
qs16 div_sat_qs16 (qs16 VopA, qs16 VopB, int fixed_point_position)
 
qs8x2 exp_sat_qs8x2 (qs8x2 VopA, int fixed_point_position)
 
qs8x4 exp_sat_qs8x4 (qs8x4 VopA, int fixed_point_position)
 
qs8x8 exp_sat_qs8x8 (qs8x8 VopA, int fixed_point_position)
 
qs8x16 exp_sat_qs8x16 (qs8x16 VopA, int fixed_point_position)
 
qs16x2 exp_sat_qs16x2 (qs16x2 VopA, int fixed_point_position)
 
qs16x4 exp_sat_qs16x4 (qs16x4 VopA, int fixed_point_position)
 
qs16x8 exp_sat_qs16x8 (qs16x8 VopA, int fixed_point_position)
 
qs16x16 exp_sat_qs16x16 (qs16x16 VopA, int fixed_point_position)
 
qs8x16 log_sat_qs8x16 (qs8x16 VopA, int fixed_point_position)
 
qs16x8 log_sat_qs16x8 (qs16x8 VopA, int fixed_point_position)
 
qs16x16 log_sat_qs16x16 (qs16x16 VopA, int fixed_point_position)
 
qs8x1 invsqrt_sat_qs8x1 (qs8x1 VopA, int fixed_point_position)
 
qs16x1 invsqrt_sat_qs16x1 (qs16x1 VopA, int fixed_point_position)
 
qs8x16 invsqrt_sat_qs8x16 (qs8x16 VopA, int fixed_point_position)
 
qs16x8 invsqrt_sat_qs16x8 (qs16x8 VopA, int fixed_point_position)
 
qs8x16 tanh_sat_qs8x16 (qs8x16 VopA, int fixed_point_position)
 
qs16x8 tanh_sat_qs16x8 (qs16x8 VopA, int fixed_point_position)
 
qs8x16 convert_qs8x16_float16 (float16 a, int fixed_point_position)
 
qs16x16 convert_qs16x16_float16 (float16 a, int fixed_point_position)
 
qs8x16 convert_qs8x16_float16_sat (float16 a, int fixed_point_position)
 
qs16x16 convert_qs16x16_float16_sat (float16 a, int fixed_point_position)
 
float16 convert_float16_qs8x16 (qs8x16 a, int fixed_point_position)
 
float16 convert_float16_qs16x16 (qs16x16 a, int fixed_point_position)
 
qs8 sqcvt_qs8_sat (float a, int fixed_point_position)
 
qs16 sqcvt_qs16_sat (float a, int fixed_point_position)
 

Macro Definition Documentation

#define ABS_SAT_OP_EXPAND (   a,
  type,
  size 
)    ABS_SAT_OP_EXPAND_STR(a, type, size)

Definition at line 121 of file fixed_point.h.

#define ABS_SAT_OP_EXPAND_STR (   a,
  type,
  size 
)    abs_##type##x##size##_sat((a))

Definition at line 120 of file fixed_point.h.

#define ABSQ_SAT_IMPL (   type)
Value:
inline type abs_##type##_sat(type VopA) \
{ \
return CONVERT_SAT(abs(VopA), type); \
}
#define CONVERT_SAT(x, type)
Definition: fixed_point.h:103
fixed_point< T > abs(fixed_point< T > x)
Definition: FixedPoint.h:914

Computes saturating absolute value of fixed point vector.

Parameters
[in]typethe actual data type.
Returns
The result of the fixed point absolute value.

Definition at line 111 of file fixed_point.h.

#define ADD_SAT_OP_EXPAND (   a,
  b,
  type,
  size 
)    ADD_SAT_OP_EXPAND_STR(a, b, type, size)

Definition at line 178 of file fixed_point.h.

#define ADD_SAT_OP_EXPAND_STR (   a,
  b,
  type,
  size 
)    add_sat_##type##x##size((a), (b))

Definition at line 177 of file fixed_point.h.

#define ADDQ_SAT_IMPL (   type)
Value:
inline type add_sat_##type(type VopA, type VopB) \
{ \
return add_sat(VopA, VopB); \
}

Computes saturated addition of fixed point types.

Parameters
[in]typethe actual data type.
Returns
The result of the fixed point addition. The result is saturated in case of overflow

Definition at line 155 of file fixed_point.h.

#define CONVERT_SAT (   x,
  type 
)    CONVERT_SAT_STR(x, type)

Definition at line 103 of file fixed_point.h.

#define CONVERT_SAT_STR (   x,
  type 
)    CONVERT_SAT_STR2(x, type, type##_TYPE)

Definition at line 102 of file fixed_point.h.

#define CONVERT_SAT_STR2 (   x,
  type,
  rtype 
)    CONVERT_SAT_STR3(x, type, rtype)

Definition at line 101 of file fixed_point.h.

#define CONVERT_SAT_STR3 (   x,
  type,
  rtype 
)    (convert_##rtype##_sat((x)))

Definition at line 100 of file fixed_point.h.

#define CONVERT_STR (   x,
  type 
)    CONVERT_STR2(x, type, type##_TYPE)

Definition at line 97 of file fixed_point.h.

#define CONVERT_STR2 (   x,
  type,
  rtype 
)    CONVERT_STR3(x, type, rtype)

Definition at line 96 of file fixed_point.h.

#define CONVERT_STR3 (   x,
  type,
  rtype 
)    (convert_##rtype((x)))

Definition at line 95 of file fixed_point.h.

#define CONVERTQ_DOWN_IMPL (   in_type,
  out_type 
)
Value:
inline out_type convert_##out_type##_##in_type(in_type a, int fixed_point_position) \
{ \
return CONVERT(a * (1 << fixed_point_position) + select((in_type)-0.5f, (in_type)0.5f, isgreater(a, (in_type)0)), out_type); \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98

Definition at line 479 of file fixed_point.h.

#define CONVERTQ_DOWN_SAT_IMPL (   in_type,
  out_type 
)
Value:
inline out_type convert_##out_type##_##in_type##_sat(in_type a, int fixed_point_position) \
{ \
return CONVERT_SAT(a * (1 << fixed_point_position) + select((in_type)-0.5f, (in_type)0.5f, isgreater(a, (in_type)0)), out_type); \
}
#define CONVERT_SAT(x, type)
Definition: fixed_point.h:103

Definition at line 488 of file fixed_point.h.

#define CONVERTQ_UP_IMPL (   in_type,
  out_type 
)
Value:
inline out_type convert_##out_type##_##in_type(in_type a, int fixed_point_position) \
{ \
return CONVERT(a, out_type) / (1 << fixed_point_position); \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98

Definition at line 497 of file fixed_point.h.

#define DIV_SAT_OP_EXPAND (   a,
  b,
  type,
  position 
)    DIV_SAT_OP_EXPAND_STR(a, b, type, position)

Definition at line 326 of file fixed_point.h.

#define DIV_SAT_OP_EXPAND_STR (   a,
  b,
  type,
  position 
)    div_sat_##type((a), (b), (position))

Definition at line 325 of file fixed_point.h.

#define DIV_SAT_OP_VEC_EXPAND (   a,
  b,
  type,
  size,
  position 
)    DIV_SAT_OP_VEC_EXPAND_STR(a, b, type, size, position)

Definition at line 329 of file fixed_point.h.

#define DIV_SAT_OP_VEC_EXPAND_STR (   a,
  b,
  type,
  size,
  position 
)    div_sat_##type##x##size((a), (b), (position))

Definition at line 328 of file fixed_point.h.

#define DIVQ_SAT_IMPL (   stype,
  type,
  itype 
)
Value:
inline type div_sat_##type(type VopA, type VopB, int fixed_point_position) \
{ \
itype conv_a = CONVERT((VopA), itype); \
itype denominator = CONVERT((VopB), itype); \
itype numerator = conv_a << (itype)(fixed_point_position); \
itype res = select((itype)(numerator / denominator), select((itype)stype##_MAX, (itype)stype##_MIN, (itype)(conv_a < (itype)0)), (itype)(denominator == (itype)0)); \
return CONVERT_SAT((res), type); \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98
#define CONVERT_SAT(x, type)
Definition: fixed_point.h:103

Saturate division of two fixed point vectors.

Parameters
[in]stypethe actual scalar data type.
[in]typethe actual data type.
[in]itypethe intermediate data type.
Returns
The result of the fixed point division. The result is saturated in case of overflow

Definition at line 309 of file fixed_point.h.

#define EXP_OP_EXPAND (   a,
  type,
  size,
  position 
)    EXP_OP_EXPAND_STR(a, type, size, position)

Definition at line 372 of file fixed_point.h.

#define EXP_OP_EXPAND_STR (   a,
  type,
  size,
  position 
)    exp_sat_##type##x##size((a), (position))

Definition at line 371 of file fixed_point.h.

#define EXPQ_IMPL (   stype,
  type,
  size 
)
Value:
inline type exp_sat_##type(type VopA, int fixed_point_position) \
{ \
type const_one = (type)(1 << (fixed_point_position)); \
type ln2 = (type)((((0x58B9 >> (14 - fixed_point_position))) + 1) >> 1); \
type inv_ln2 = (type)((((0x38AA >> (14 - fixed_point_position)) + 1) >> 1)) | const_one; \
type A = (type)(((0x7FBA >> (14 - fixed_point_position)) + 1) >> 1); \
type B = (type)(((0x3FE9 >> (14 - fixed_point_position)) + 1) >> 1); \
type C = (type)(((0x1693 >> (14 - fixed_point_position)) + 1) >> 1); \
type D = (type)(((0x0592 >> (14 - fixed_point_position)) + 1) >> 1); \
type m = MUL_SAT_OP_EXPAND(VopA, inv_ln2, stype, size, fixed_point_position); \
type dec_m = m >> (type)fixed_point_position; \
type alpha = MUL_SAT_OP_EXPAND(dec_m << (type)fixed_point_position, ln2, stype, size, fixed_point_position); \
alpha = CONVERT(abs_diff(VopA, alpha), type); \
type sum = add_sat(MUL_SAT_OP_EXPAND(alpha, D, stype, size, fixed_point_position), C); \
sum = add_sat(MUL_SAT_OP_EXPAND(alpha, sum, stype, size, fixed_point_position), B); \
sum = add_sat(MUL_SAT_OP_EXPAND(alpha, sum, stype, size, fixed_point_position), A); \
sum = add_sat(MUL_SAT_OP_EXPAND(alpha, sum, stype, size, fixed_point_position), const_one); \
return select((type)stype##_MAX, select(sum << dec_m, sum >> -dec_m, dec_m < (type)0), clz(sum) > dec_m); /* Saturate result if needed */ \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98
DATA_TYPE sum(__global const DATA_TYPE *input)
Calculate sum of a vector.
uint32_t size
Definition: hwc.hpp:286
constexpr int clz(T value)
Count the number of leading zero bits in the given value.
Definition: FixedPoint.h:276
#define MUL_SAT_OP_EXPAND(a, b, type, size, position)
Definition: fixed_point.h:258

Saturate exponential of a fixed point vector.

Note
Implemented approach uses taylor polynomial to approximate the exponential function.
Parameters
[in]stypethe actual scalar data type.
[in]typethe actual data type.
[in]sizethe number of the calculated elements.
Returns
The result of the fixed point exponential. The result is saturated in case of overflow

Definition at line 341 of file fixed_point.h.

#define float16_TYPE   float16

Definition at line 477 of file fixed_point.h.

#define floatx16   float16

Definition at line 476 of file fixed_point.h.

#define INVSQRT_OP_EXPAND (   a,
  type,
  size,
  position 
)    INVSQRT_OP_EXPAND_STR(a, type, size, position)

Definition at line 447 of file fixed_point.h.

#define INVSQRT_OP_EXPAND_STR (   a,
  type,
  size,
  position 
)    invsqrt_sat_##type##x##size((a), (position))

Definition at line 446 of file fixed_point.h.

#define INVSQRTQ_IMPL (   stype,
  type,
  size 
)
Value:
inline type invsqrt_sat_##type(type VopA, int fixed_point_position) \
{ \
type const_three = (type)(3 << (fixed_point_position)); \
type shift_value = (type)(16 - stype##_SHIFT) - (clz(VopA) + (type)fixed_point_position); \
type temp = select((type)(VopA >> shift_value), select((type)stype##_MAX, (type)(VopA << (-shift_value)), (type)(clz(VopA) > (-shift_value))), (type)(shift_value < (type)0)); \
type x = temp; \
x = MUL_SAT_OP_EXPAND(x, sub_sat(const_three, MUL_SAT_OP_EXPAND(MUL_SAT_OP_EXPAND(x, x, stype, size, fixed_point_position), temp, stype, size, fixed_point_position)), stype, size, fixed_point_position) >> 1; \
x = MUL_SAT_OP_EXPAND(x, sub_sat(const_three, MUL_SAT_OP_EXPAND(MUL_SAT_OP_EXPAND(x, x, stype, size, fixed_point_position), temp, stype, size, fixed_point_position)), stype, size, fixed_point_position) >> 1; \
x = MUL_SAT_OP_EXPAND(x, sub_sat(const_three, MUL_SAT_OP_EXPAND(MUL_SAT_OP_EXPAND(x, x, stype, size, fixed_point_position), temp, stype, size, fixed_point_position)), stype, size, fixed_point_position) >> 1; \
if(sizeof((stype)(1)) > 1) /* Perform more iterations if datatype is QS16 */ \
{ \
x = MUL_SAT_OP_EXPAND(x, sub_sat(const_three, MUL_SAT_OP_EXPAND(MUL_SAT_OP_EXPAND(x, x, stype, size, fixed_point_position), temp, stype, size, fixed_point_position)), stype, size, fixed_point_position) >> 1; \
x = MUL_SAT_OP_EXPAND(x, sub_sat(const_three, MUL_SAT_OP_EXPAND(MUL_SAT_OP_EXPAND(x, x, stype, size, fixed_point_position), temp, stype, size, fixed_point_position)), stype, size, fixed_point_position) >> 1; \
} \
type shift_value2 = select(shift_value >> 1, (-shift_value) >> 1, shift_value < (type)0); \
return select((type)(x >> shift_value2), select((type)stype##_MAX, (type)(x << shift_value2), (type)(clz(x) > shift_value2)), (type)(shift_value < (type)0)); /* Saturate result if needed */ \
}
uint32_t size
Definition: hwc.hpp:286
constexpr int clz(T value)
Count the number of leading zero bits in the given value.
Definition: FixedPoint.h:276
#define MUL_SAT_OP_EXPAND(a, b, type, size, position)
Definition: fixed_point.h:258

Saturate inverse square root of a fixed point vector.

Note
Implemented approach uses Newton's method to approximate the inverse square root function.
Parameters
[in]stypethe actual scalar data type.
[in]typethe actual data type.
[in]sizethe number of the calculated elements.
Returns
The result of the fixed point inverse square root. The result is saturated in case of overflow

Definition at line 422 of file fixed_point.h.

#define LOG_OP_EXPAND (   a,
  type,
  size,
  position 
)    LOG_OP_EXPAND_STR(a, type, size, position)

Definition at line 410 of file fixed_point.h.

#define LOG_OP_EXPAND_STR (   a,
  type,
  size,
  position 
)    log_sat_##type##x##size((a), (position))

Definition at line 409 of file fixed_point.h.

#define LOGQ_IMPL (   stype,
  type,
  size 
)
Value:
inline type log_sat_##type(type VopA, int fixed_point_position) \
{ \
type const_one = (type)(1 << (fixed_point_position)); \
type ln2 = (type)(0x58B9 >> (15 - fixed_point_position)); /* 1.4384189 */ \
type A = (type)(0x5C0F >> (14 - fixed_point_position)); /* 1.4384189 */ \
type B = -(type)(0x56AE >> (15 - fixed_point_position)); /* -0.6771900 */ \
type C = (type)(0x2933 >> (15 - fixed_point_position)); /* 0.3218538 */ \
type D = -(type)(0x0AA7 >> (15 - fixed_point_position)); /* -0.0832229 */ \
type inter_a = select(VopA, DIV_SAT_OP_VEC_EXPAND(const_one, VopA, stype, size, fixed_point_position), VopA < const_one); \
type shift_val = (type)(15 - stype##_SHIFT) - clz(inter_a >> (type)fixed_point_position); \
inter_a = inter_a >> shift_val; \
inter_a = sub_sat(inter_a, const_one); \
type sum = add_sat(MUL_SAT_OP_EXPAND(inter_a, D, stype, size, fixed_point_position), C); \
sum = add_sat(MUL_SAT_OP_EXPAND(inter_a, sum, stype, size, fixed_point_position), B); \
sum = add_sat(MUL_SAT_OP_EXPAND(inter_a, sum, stype, size, fixed_point_position), A); \
sum = MUL_SAT_OP_EXPAND(inter_a, sum, stype, size, fixed_point_position); \
sum = MUL_SAT_OP_EXPAND(add_sat(sum, shift_val << (type)fixed_point_position), ln2, stype, size, fixed_point_position); \
return select(select(sum, -sum, VopA < const_one), (type)0, VopA < (type)0); /* Saturate result if needed */ \
}
DATA_TYPE sum(__global const DATA_TYPE *input)
Calculate sum of a vector.
uint32_t size
Definition: hwc.hpp:286
#define DIV_SAT_OP_VEC_EXPAND(a, b, type, size, position)
Definition: fixed_point.h:329
constexpr int clz(T value)
Count the number of leading zero bits in the given value.
Definition: FixedPoint.h:276
#define MUL_SAT_OP_EXPAND(a, b, type, size, position)
Definition: fixed_point.h:258

Saturate logarithm of a fixed point vector.

Note
Implemented approach uses taylor polynomial to approximate the logarithm function.
Parameters
[in]stypethe actual scalar data type.
[in]typethe actual data type.
[in]sizethe number of the calculated elements.
Returns
The result of the fixed point logarithm. The result is saturated in case of overflow

Definition at line 384 of file fixed_point.h.

#define MAX_OP_EXPAND (   a,
  b,
  type,
  size 
)    MAX_OP_EXPAND_STR(a, b, type, size)

Definition at line 147 of file fixed_point.h.

#define MAX_OP_EXPAND_STR (   a,
  b,
  type,
  size 
)    max_##type##x##size((a), (b))

Definition at line 146 of file fixed_point.h.

#define MAXQ_IMPL (   type)
Value:
inline type max_##type(type VopA, type VopB) \
{ \
return max(VopA, VopB); \
}
fixed_point< T > max(fixed_point< T > x, fixed_point< T > y)
Definition: FixedPoint.h:889

Computes max of fixed point types.

Parameters
[in]typethe actual data type.
Returns
The result of the fixed point maximum.

Definition at line 129 of file fixed_point.h.

#define MLA_SAT_OP_EXPAND (   a,
  b,
  c,
  type,
  size,
  position 
)    MLA_SAT_OP_EXPAND_STR(a, b, c, type, size, position)

Definition at line 279 of file fixed_point.h.

#define MLA_SAT_OP_EXPAND_STR (   a,
  b,
  c,
  type,
  size,
  position 
)    mla_sat_##type##x##size((a), (b), (c), (position))

Definition at line 278 of file fixed_point.h.

#define MLAL_SAT_OP_EXPAND (   a,
  b,
  c,
  type,
  size,
  position 
)    MLAL_SAT_OP_EXPAND_STR(a, b, c, type, size, position)

Definition at line 299 of file fixed_point.h.

#define MLAL_SAT_OP_EXPAND_STR (   a,
  b,
  c,
  type,
  size,
  position 
)    mlal_sat_##type##x##size((a), (b), (c), (position))

Definition at line 298 of file fixed_point.h.

#define MLALQ_SAT_IMPL (   type,
  itype 
)
Value:
itype mlal_sat_##type(itype VopA, type VopB, type VopC, int fixed_point_position) \
{ \
itype res = mad_sat(CONVERT(VopB, itype), CONVERT(VopC, itype), (itype)(1 << (fixed_point_position - 1))); \
return add_sat(VopA, res >> (itype)fixed_point_position); \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98

Saturate multiply-accumulate long.

Parameters
[in]typethe actual data type.
[in]itypethe intermediate data type.
Returns
The result of the fixed point multiply-accumulate long. The result is saturated in case of overflow

Definition at line 288 of file fixed_point.h.

#define MLAQ_SAT_IMPL (   type,
  itype 
)
Value:
type mla_sat_##type(type VopA, type VopB, type VopC, int fixed_point_position) \
{ \
itype res = mad_sat(CONVERT(VopB, itype), CONVERT(VopC, itype), (itype)(1 << (fixed_point_position - 1))); \
return add_sat(VopA, CONVERT_SAT(res >> (itype)fixed_point_position, type)); \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98
#define CONVERT_SAT(x, type)
Definition: fixed_point.h:103

Saturate multiply-accumulate.

Parameters
[in]typethe actual data type.
[in]itypethe intermediate data type.
Returns
The result of the fixed point multiply-accumulate. The result is saturated in case of overflow

Definition at line 267 of file fixed_point.h.

#define MUL_OP_EXPAND (   a,
  b,
  type,
  size,
  position 
)    MUL_OP_EXPAND_STR(a, b, type, size, position)

Definition at line 227 of file fixed_point.h.

#define MUL_OP_EXPAND_STR (   a,
  b,
  type,
  size,
  position 
)    mul_##type##x##size((a), (b), (position))

Definition at line 226 of file fixed_point.h.

#define MUL_SAT_OP_EXPAND (   a,
  b,
  type,
  size,
  position 
)    MUL_SAT_OP_EXPAND_STR(a, b, type, size, position)

Definition at line 258 of file fixed_point.h.

#define MUL_SAT_OP_EXPAND_STR (   a,
  b,
  type,
  size,
  position 
)    mul_sat_##type##x##size((a), (b), (position))

Definition at line 257 of file fixed_point.h.

#define MULQ_IMPL (   type,
  itype 
)
Value:
inline type mul_##type(type VopA, type VopB, int fixed_point_position) \
{ \
itype round_val = (itype)(1 << (fixed_point_position - 1)); \
itype res = CONVERT((VopA), itype) * CONVERT((VopB), itype) + round_val; \
return CONVERT((res >> (itype)fixed_point_position), type); \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98

Definition at line 213 of file fixed_point.h.

#define MULQ_SAT_IMPL (   type,
  itype 
)
Value:
inline type mul_sat_##type(type VopA, type VopB, int fixed_point_position) \
{ \
itype round_val = (itype)(1 << (fixed_point_position - 1)); \
itype res = mad_sat(CONVERT((VopA), itype), CONVERT((VopB), itype), round_val); \
return CONVERT_SAT((res >> (itype)fixed_point_position), type); \
}
#define CONVERT(x, type)
Definition: fixed_point.h:98
#define CONVERT_SAT(x, type)
Definition: fixed_point.h:103

Definition at line 236 of file fixed_point.h.

#define qs16_MAX   ((short)SHRT_MAX)

Definition at line 43 of file fixed_point.h.

#define qs16_MIN   ((short)SHRT_MIN)

Definition at line 42 of file fixed_point.h.

#define qs16_SHIFT   0

Definition at line 83 of file fixed_point.h.

#define qs16_TYPE   short

Definition at line 62 of file fixed_point.h.

#define qs16x16_TYPE   short16

Definition at line 68 of file fixed_point.h.

#define qs16x1_TYPE   short

Definition at line 63 of file fixed_point.h.

#define qs16x2_TYPE   short2

Definition at line 64 of file fixed_point.h.

#define qs16x3_TYPE   short3

Definition at line 65 of file fixed_point.h.

#define qs16x4_TYPE   short4

Definition at line 66 of file fixed_point.h.

#define qs16x8_TYPE   short8

Definition at line 67 of file fixed_point.h.

#define qs32_MAX   ((int)INT_MAX)

Definition at line 45 of file fixed_point.h.

#define qs32_MIN   ((int)INT_MIN)

Definition at line 44 of file fixed_point.h.

#define qs32_TYPE   int

Definition at line 70 of file fixed_point.h.

#define qs32x16_TYPE   int16

Definition at line 76 of file fixed_point.h.

#define qs32x1_TYPE   int

Definition at line 71 of file fixed_point.h.

#define qs32x2_TYPE   int2

Definition at line 72 of file fixed_point.h.

#define qs32x3_TYPE   int3

Definition at line 73 of file fixed_point.h.

#define qs32x4_TYPE   int4

Definition at line 74 of file fixed_point.h.

#define qs32x8_TYPE   int8

Definition at line 75 of file fixed_point.h.

#define qs8_MAX   ((char)CHAR_MAX)

Definition at line 41 of file fixed_point.h.

#define qs8_MIN   ((char)CHAR_MIN)

Definition at line 40 of file fixed_point.h.

#define qs8_SHIFT   8

Definition at line 82 of file fixed_point.h.

#define qs8_TYPE   char

Definition at line 54 of file fixed_point.h.

#define qs8x16_TYPE   char16

Definition at line 60 of file fixed_point.h.

#define qs8x1_TYPE   char

Definition at line 55 of file fixed_point.h.

#define qs8x2_TYPE   char2

Definition at line 56 of file fixed_point.h.

#define qs8x3_TYPE   char3

Definition at line 57 of file fixed_point.h.

#define qs8x4_TYPE   char4

Definition at line 58 of file fixed_point.h.

#define qs8x8_TYPE   char8

Definition at line 59 of file fixed_point.h.

#define qu16_MAX   ((ushort)USHRT_MAX)

Definition at line 50 of file fixed_point.h.

#define qu16_MIN   ((ushort)0)

Definition at line 49 of file fixed_point.h.

#define qu32_MAX   ((uint)UINT_MAX)

Definition at line 52 of file fixed_point.h.

#define qu32_MIN   ((uint)0)

Definition at line 51 of file fixed_point.h.

#define qu8_MAX   ((uchar)UCHAR_MAX)

Definition at line 48 of file fixed_point.h.

#define qu8_MIN   ((uchar)0)

Definition at line 47 of file fixed_point.h.

#define SQCVT_SAT_IMPL (   type)
Value:
inline type sqcvt_##type##_sat(float a, int fixed_point_position) \
{ \
return CONVERT_SAT((a * (1 << fixed_point_position) + ((a < 0) ? -0.5f : 0.5f)), type); \
}
#define CONVERT_SAT(x, type)
Definition: fixed_point.h:103

Definition at line 506 of file fixed_point.h.

#define SQCVT_SAT_OP_EXPAND (   a,
  type,
  position 
)    SQCVT_SAT_OP_EXPAND_STR((a), type, position)

Definition at line 516 of file fixed_point.h.

#define SQCVT_SAT_OP_EXPAND_STR (   a,
  type,
  position 
)    sqcvt_##type##_sat((a), (position))

Definition at line 515 of file fixed_point.h.

#define SUB_SAT_OP_EXPAND (   a,
  b,
  type,
  size 
)    SUB_SAT_OP_EXPAND_STR(a, b, type, size)

Definition at line 204 of file fixed_point.h.

#define SUB_SAT_OP_EXPAND_STR (   a,
  b,
  type,
  size 
)    sub_sat_##type##x##size((a), (b))

Definition at line 203 of file fixed_point.h.

#define SUBQ_SAT_IMPL (   type)
Value:
inline type sub_sat_##type(type VopA, type VopB) \
{ \
return sub_sat(VopA, VopB); \
}

Computes saturated subtraction of fixed point types.

Parameters
[in]typethe actual data type.
Returns
The result of the fixed point subtraction. The result is saturated in case of overflow

Definition at line 186 of file fixed_point.h.

#define TANH_OP_EXPAND (   a,
  type,
  size,
  position 
)    TANH_OP_EXPAND_STR(a, type, size, position)

Definition at line 474 of file fixed_point.h.

#define TANH_OP_EXPAND_STR (   a,
  type,
  size,
  position 
)    tanh_sat_##type##x##size((a), (position))

Definition at line 473 of file fixed_point.h.

#define TANHQ_IMPL (   stype,
  type,
  size 
)
Value:
inline type tanh_sat_##type(type VopA, int fixed_point_position) \
{ \
type const_one = (type)(1 << (fixed_point_position)); \
type const_two = (type)(2 << (fixed_point_position)); \
type exp2x = EXP_OP_EXPAND(MUL_SAT_OP_EXPAND(const_two, VopA, stype, size, fixed_point_position), stype, size, fixed_point_position); \
type num = SUB_SAT_OP_EXPAND(exp2x, const_one, stype, size); \
type den = ADD_SAT_OP_EXPAND(exp2x, const_one, stype, size); \
return DIV_SAT_OP_VEC_EXPAND(num, den, stype, size, fixed_point_position); \
}
#define EXP_OP_EXPAND(a, type, size, position)
Definition: fixed_point.h:372
uint32_t size
Definition: hwc.hpp:286
#define SUB_SAT_OP_EXPAND(a, b, type, size)
Definition: fixed_point.h:204
#define DIV_SAT_OP_VEC_EXPAND(a, b, type, size, position)
Definition: fixed_point.h:329
#define MUL_SAT_OP_EXPAND(a, b, type, size, position)
Definition: fixed_point.h:258
#define ADD_SAT_OP_EXPAND(a, b, type, size)
Definition: fixed_point.h:178

Saturate hyperbolic tangent of a fixed point vector.

tanh(x) = (e^2x - 1)/(e^2x + 1)

Parameters
[in]stypethe actual scalar data type.
[in]typethe actual data type.
[in]sizethe number of the calculated elements.
Returns
The result of the fixed point hyperbolic tangent. The result is saturated in case of overflow

Definition at line 459 of file fixed_point.h.

#define TYPE_ALIAS (   type,
  alias 
)
Value:
typedef type alias; \
typedef type alias##x##1; \
typedef type##2 alias##x##2; \
typedef type##3 alias##x##3; \
typedef type##4 alias##x##4; \
typedef type##8 alias##x##8; \
typedef type##16 alias##x##16;

Definition at line 27 of file fixed_point.h.

#define VEC_DATA_TYPE_STR (   type,
  size 
)    type##x##size

Definition at line 92 of file fixed_point.h.

Typedef Documentation

typedef short qs16

Definition at line 37 of file fixed_point.h.

typedef short qs16x1

Definition at line 37 of file fixed_point.h.

typedef short16 qs16x16

Definition at line 37 of file fixed_point.h.

typedef short2 qs16x2

Definition at line 37 of file fixed_point.h.

typedef short3 qs16x3

Definition at line 37 of file fixed_point.h.

typedef short4 qs16x4

Definition at line 37 of file fixed_point.h.

typedef short8 qs16x8

Definition at line 37 of file fixed_point.h.

typedef int qs32

Definition at line 38 of file fixed_point.h.

typedef int qs32x1

Definition at line 38 of file fixed_point.h.

typedef int16 qs32x16

Definition at line 38 of file fixed_point.h.

typedef int2 qs32x2

Definition at line 38 of file fixed_point.h.

typedef int3 qs32x3

Definition at line 38 of file fixed_point.h.

typedef int4 qs32x4

Definition at line 38 of file fixed_point.h.

typedef int8 qs32x8

Definition at line 38 of file fixed_point.h.

typedef char qs8

Definition at line 36 of file fixed_point.h.

typedef char qs8x1

Definition at line 36 of file fixed_point.h.

typedef char16 qs8x16

Definition at line 36 of file fixed_point.h.

typedef char2 qs8x2

Definition at line 36 of file fixed_point.h.

typedef char3 qs8x3

Definition at line 36 of file fixed_point.h.

typedef char4 qs8x4

Definition at line 36 of file fixed_point.h.

typedef char8 qs8x8

Definition at line 36 of file fixed_point.h.

Function Documentation

qs16x8 abs_qs16x8_sat ( qs16x8  VopA)
inline

Definition at line 118 of file fixed_point.h.

131 { \
qs8x16 abs_qs8x16_sat ( qs8x16  VopA)
inline

Definition at line 117 of file fixed_point.h.

131 { \
qs16x1 add_sat_qs16x1 ( qs16x1  VopA,
qs16x1  VopB 
)
inline

Definition at line 166 of file fixed_point.h.

188 { \
qs16x16 add_sat_qs16x16 ( qs16x16  VopA,
qs16x16  VopB 
)
inline

Definition at line 170 of file fixed_point.h.

188 { \
qs16x2 add_sat_qs16x2 ( qs16x2  VopA,
qs16x2  VopB 
)
inline

Definition at line 167 of file fixed_point.h.

188 { \
qs16x4 add_sat_qs16x4 ( qs16x4  VopA,
qs16x4  VopB 
)
inline

Definition at line 168 of file fixed_point.h.

188 { \
qs16x8 add_sat_qs16x8 ( qs16x8  VopA,
qs16x8  VopB 
)
inline

Definition at line 169 of file fixed_point.h.

188 { \
qs32x1 add_sat_qs32x1 ( qs32x1  VopA,
qs32x1  VopB 
)
inline

Definition at line 171 of file fixed_point.h.

188 { \
qs32x16 add_sat_qs32x16 ( qs32x16  VopA,
qs32x16  VopB 
)
inline

Definition at line 175 of file fixed_point.h.

188 { \
qs32x2 add_sat_qs32x2 ( qs32x2  VopA,
qs32x2  VopB 
)
inline

Definition at line 172 of file fixed_point.h.

188 { \
qs32x4 add_sat_qs32x4 ( qs32x4  VopA,
qs32x4  VopB 
)
inline

Definition at line 173 of file fixed_point.h.

188 { \
qs32x8 add_sat_qs32x8 ( qs32x8  VopA,
qs32x8  VopB 
)
inline

Definition at line 174 of file fixed_point.h.

188 { \
qs8x1 add_sat_qs8x1 ( qs8x1  VopA,
qs8x1  VopB 
)
inline

Definition at line 161 of file fixed_point.h.

188 { \
qs8x16 add_sat_qs8x16 ( qs8x16  VopA,
qs8x16  VopB 
)
inline

Definition at line 165 of file fixed_point.h.

188 { \
qs8x2 add_sat_qs8x2 ( qs8x2  VopA,
qs8x2  VopB 
)
inline

Definition at line 162 of file fixed_point.h.

188 { \
qs8x4 add_sat_qs8x4 ( qs8x4  VopA,
qs8x4  VopB 
)
inline

Definition at line 163 of file fixed_point.h.

188 { \
qs8x8 add_sat_qs8x8 ( qs8x8  VopA,
qs8x8  VopB 
)
inline

Definition at line 164 of file fixed_point.h.

188 { \
float16 convert_float16_qs16x16 ( qs16x16  a,
int  fixed_point_position 
)
inline

Definition at line 504 of file fixed_point.h.

508 { \
float16 convert_float16_qs8x16 ( qs8x16  a,
int  fixed_point_position 
)
inline

Definition at line 503 of file fixed_point.h.

508 { \
qs16x16 convert_qs16x16_float16 ( float16  a,
int  fixed_point_position 
)
inline

Definition at line 486 of file fixed_point.h.

490 { \
qs16x16 convert_qs16x16_float16_sat ( float16  a,
int  fixed_point_position 
)
inline

Definition at line 495 of file fixed_point.h.

499 { \
qs8x16 convert_qs8x16_float16 ( float16  a,
int  fixed_point_position 
)
inline

Definition at line 485 of file fixed_point.h.

490 { \
qs8x16 convert_qs8x16_float16_sat ( float16  a,
int  fixed_point_position 
)
inline

Definition at line 494 of file fixed_point.h.

499 { \
qs16 div_sat_qs16 ( qs16  VopA,
qs16  VopB,
int  fixed_point_position 
)
inline

Definition at line 323 of file fixed_point.h.

343 { \
qs16x16 div_sat_qs16x16 ( qs16x16  VopA,
qs16x16  VopB,
int  fixed_point_position 
)
inline

Definition at line 321 of file fixed_point.h.

343 { \
qs16x8 div_sat_qs16x8 ( qs16x8  VopA,
qs16x8  VopB,
int  fixed_point_position 
)
inline

Definition at line 320 of file fixed_point.h.

343 { \
qs8 div_sat_qs8 ( qs8  VopA,
qs8  VopB,
int  fixed_point_position 
)
inline

Definition at line 322 of file fixed_point.h.

343 { \
qs8x16 div_sat_qs8x16 ( qs8x16  VopA,
qs8x16  VopB,
int  fixed_point_position 
)
inline

Definition at line 319 of file fixed_point.h.

343 { \
qs16x16 exp_sat_qs16x16 ( qs16x16  VopA,
int  fixed_point_position 
)
inline

Definition at line 369 of file fixed_point.h.

386 { \
qs16x2 exp_sat_qs16x2 ( qs16x2  VopA,
int  fixed_point_position 
)
inline

Definition at line 366 of file fixed_point.h.

386 { \
qs16x4 exp_sat_qs16x4 ( qs16x4  VopA,
int  fixed_point_position 
)
inline

Definition at line 367 of file fixed_point.h.

386 { \
qs16x8 exp_sat_qs16x8 ( qs16x8  VopA,
int  fixed_point_position 
)
inline

Definition at line 368 of file fixed_point.h.

386 { \
qs8x16 exp_sat_qs8x16 ( qs8x16  VopA,
int  fixed_point_position 
)
inline

Definition at line 365 of file fixed_point.h.

386 { \
qs8x2 exp_sat_qs8x2 ( qs8x2  VopA,
int  fixed_point_position 
)
inline

Definition at line 362 of file fixed_point.h.

386 { \
qs8x4 exp_sat_qs8x4 ( qs8x4  VopA,
int  fixed_point_position 
)
inline

Definition at line 363 of file fixed_point.h.

386 { \
qs8x8 exp_sat_qs8x8 ( qs8x8  VopA,
int  fixed_point_position 
)
inline

Definition at line 364 of file fixed_point.h.

386 { \
qs16x1 invsqrt_sat_qs16x1 ( qs16x1  VopA,
int  fixed_point_position 
)
inline

Definition at line 442 of file fixed_point.h.

461 { \
qs16x8 invsqrt_sat_qs16x8 ( qs16x8  VopA,
int  fixed_point_position 
)
inline

Definition at line 444 of file fixed_point.h.

461 { \
qs8x1 invsqrt_sat_qs8x1 ( qs8x1  VopA,
int  fixed_point_position 
)
inline

Definition at line 441 of file fixed_point.h.

461 { \
qs8x16 invsqrt_sat_qs8x16 ( qs8x16  VopA,
int  fixed_point_position 
)
inline

Definition at line 443 of file fixed_point.h.

461 { \
qs16x16 log_sat_qs16x16 ( qs16x16  VopA,
int  fixed_point_position 
)
inline

Definition at line 407 of file fixed_point.h.

424 { \
qs16x8 log_sat_qs16x8 ( qs16x8  VopA,
int  fixed_point_position 
)
inline

Definition at line 406 of file fixed_point.h.

424 { \
qs8x16 log_sat_qs8x16 ( qs8x16  VopA,
int  fixed_point_position 
)
inline

Definition at line 405 of file fixed_point.h.

424 { \
qs16x1 max_qs16x1 ( qs16x1  VopA,
qs16x1  VopB 
)
inline

Definition at line 140 of file fixed_point.h.

157 { \
qs16x16 max_qs16x16 ( qs16x16  VopA,
qs16x16  VopB 
)
inline

Definition at line 144 of file fixed_point.h.

157 { \
qs16x2 max_qs16x2 ( qs16x2  VopA,
qs16x2  VopB 
)
inline

Definition at line 141 of file fixed_point.h.

157 { \
qs16x4 max_qs16x4 ( qs16x4  VopA,
qs16x4  VopB 
)
inline

Definition at line 142 of file fixed_point.h.

157 { \
qs16x8 max_qs16x8 ( qs16x8  VopA,
qs16x8  VopB 
)
inline

Definition at line 143 of file fixed_point.h.

157 { \
qs8x1 max_qs8x1 ( qs8x1  VopA,
qs8x1  VopB 
)
inline

Definition at line 135 of file fixed_point.h.

157 { \
qs8x16 max_qs8x16 ( qs8x16  VopA,
qs8x16  VopB 
)
inline

Definition at line 139 of file fixed_point.h.

157 { \
qs8x2 max_qs8x2 ( qs8x2  VopA,
qs8x2  VopB 
)
inline

Definition at line 136 of file fixed_point.h.

157 { \
qs8x4 max_qs8x4 ( qs8x4  VopA,
qs8x4  VopB 
)
inline

Definition at line 137 of file fixed_point.h.

157 { \
qs8x8 max_qs8x8 ( qs8x8  VopA,
qs8x8  VopB 
)
inline

Definition at line 138 of file fixed_point.h.

157 { \
qs16x8 mla_sat_qs16x8 ( qs16x8  VopA,
qs16x8  VopB,
qs16x8  VopC,
int  fixed_point_position 
)

Definition at line 276 of file fixed_point.h.

290 { \
qs8x16 mla_sat_qs8x16 ( qs8x16  VopA,
qs8x16  VopB,
qs8x16  VopC,
int  fixed_point_position 
)

Definition at line 275 of file fixed_point.h.

290 { \
qs8x8 mla_sat_qs8x8 ( qs8x8  VopA,
qs8x8  VopB,
qs8x8  VopC,
int  fixed_point_position 
)

Definition at line 274 of file fixed_point.h.

290 { \
qs32x8 mlal_sat_qs16x8 ( qs32x8  VopA,
qs16x8  VopB,
qs16x8  VopC,
int  fixed_point_position 
)

Definition at line 296 of file fixed_point.h.

311 { \
qs16x8 mlal_sat_qs8x8 ( qs16x8  VopA,
qs8x8  VopB,
qs8x8  VopC,
int  fixed_point_position 
)

Definition at line 295 of file fixed_point.h.

311 { \
qs16x16 mul_qs16x16 ( qs16x16  VopA,
qs16x16  VopB,
int  fixed_point_position 
)
inline

Definition at line 224 of file fixed_point.h.

238 { \
qs16x8 mul_qs16x8 ( qs16x8  VopA,
qs16x8  VopB,
int  fixed_point_position 
)
inline

Definition at line 222 of file fixed_point.h.

238 { \
qs8x16 mul_qs8x16 ( qs8x16  VopA,
qs8x16  VopB,
int  fixed_point_position 
)
inline

Definition at line 223 of file fixed_point.h.

238 { \
qs8x8 mul_qs8x8 ( qs8x8  VopA,
qs8x8  VopB,
int  fixed_point_position 
)
inline

Definition at line 221 of file fixed_point.h.

238 { \
qs16x1 mul_sat_qs16x1 ( qs16x1  VopA,
qs16x1  VopB,
int  fixed_point_position 
)
inline

Definition at line 250 of file fixed_point.h.

269 { \
qs16x16 mul_sat_qs16x16 ( qs16x16  VopA,
qs16x16  VopB,
int  fixed_point_position 
)
inline

Definition at line 255 of file fixed_point.h.

269 { \
qs16x2 mul_sat_qs16x2 ( qs16x2  VopA,
qs16x2  VopB,
int  fixed_point_position 
)
inline

Definition at line 251 of file fixed_point.h.

269 { \
qs16x3 mul_sat_qs16x3 ( qs16x3  VopA,
qs16x3  VopB,
int  fixed_point_position 
)
inline

Definition at line 252 of file fixed_point.h.

269 { \
qs16x4 mul_sat_qs16x4 ( qs16x4  VopA,
qs16x4  VopB,
int  fixed_point_position 
)
inline

Definition at line 253 of file fixed_point.h.

269 { \
qs16x8 mul_sat_qs16x8 ( qs16x8  VopA,
qs16x8  VopB,
int  fixed_point_position 
)
inline

Definition at line 254 of file fixed_point.h.

269 { \
qs8x1 mul_sat_qs8x1 ( qs8x1  VopA,
qs8x1  VopB,
int  fixed_point_position 
)
inline

Definition at line 244 of file fixed_point.h.

269 { \
qs8x16 mul_sat_qs8x16 ( qs8x16  VopA,
qs8x16  VopB,
int  fixed_point_position 
)
inline

Definition at line 249 of file fixed_point.h.

269 { \
qs8x2 mul_sat_qs8x2 ( qs8x2  VopA,
qs8x2  VopB,
int  fixed_point_position 
)
inline

Definition at line 245 of file fixed_point.h.

269 { \
qs8x3 mul_sat_qs8x3 ( qs8x3  VopA,
qs8x3  VopB,
int  fixed_point_position 
)
inline

Definition at line 246 of file fixed_point.h.

269 { \
qs8x4 mul_sat_qs8x4 ( qs8x4  VopA,
qs8x4  VopB,
int  fixed_point_position 
)
inline

Definition at line 247 of file fixed_point.h.

269 { \
qs8x8 mul_sat_qs8x8 ( qs8x8  VopA,
qs8x8  VopB,
int  fixed_point_position 
)
inline

Definition at line 248 of file fixed_point.h.

269 { \
qs16 sqcvt_qs16_sat ( float  a,
int  fixed_point_position 
)
inline

Definition at line 513 of file fixed_point.h.

qs8 sqcvt_qs8_sat ( float  a,
int  fixed_point_position 
)
inline

Definition at line 512 of file fixed_point.h.

qs16x1 sub_sat_qs16x1 ( qs16x1  VopA,
qs16x1  VopB 
)
inline

Definition at line 197 of file fixed_point.h.

215 { \
qs16x16 sub_sat_qs16x16 ( qs16x16  VopA,
qs16x16  VopB 
)
inline

Definition at line 201 of file fixed_point.h.

215 { \
qs16x2 sub_sat_qs16x2 ( qs16x2  VopA,
qs16x2  VopB 
)
inline

Definition at line 198 of file fixed_point.h.

215 { \
qs16x4 sub_sat_qs16x4 ( qs16x4  VopA,
qs16x4  VopB 
)
inline

Definition at line 199 of file fixed_point.h.

215 { \
qs16x8 sub_sat_qs16x8 ( qs16x8  VopA,
qs16x8  VopB 
)
inline

Definition at line 200 of file fixed_point.h.

215 { \
qs8x1 sub_sat_qs8x1 ( qs8x1  VopA,
qs8x1  VopB 
)
inline

Definition at line 192 of file fixed_point.h.

215 { \
qs8x16 sub_sat_qs8x16 ( qs8x16  VopA,
qs8x16  VopB 
)
inline

Definition at line 196 of file fixed_point.h.

215 { \
qs8x2 sub_sat_qs8x2 ( qs8x2  VopA,
qs8x2  VopB 
)
inline

Definition at line 193 of file fixed_point.h.

215 { \
qs8x4 sub_sat_qs8x4 ( qs8x4  VopA,
qs8x4  VopB 
)
inline

Definition at line 194 of file fixed_point.h.

215 { \
qs8x8 sub_sat_qs8x8 ( qs8x8  VopA,
qs8x8  VopB 
)
inline

Definition at line 195 of file fixed_point.h.

215 { \
qs16x8 tanh_sat_qs16x8 ( qs16x8  VopA,
int  fixed_point_position 
)
inline

Definition at line 471 of file fixed_point.h.

481 { \
qs8x16 tanh_sat_qs8x16 ( qs8x16  VopA,
int  fixed_point_position 
)
inline

Definition at line 470 of file fixed_point.h.

481 { \