DSPLIB User Guide
DSPLIB_bexp_ci.cpp File Reference

Go to the source code of this file.

Macros

#define SE_PARAM_BASE   (0x0000)
 
#define SE_SE0_PARAM_OFFSET   (SE_PARAM_BASE)
 
#define SE_SE1_PARAM_OFFSET   (SE_SE0_PARAM_OFFSET + SE_PARAM_SIZE)
 
#define LAST_VEC_AND_MASK_OFFSET   (SE_PARAM_BASE)
 

Functions

template<typename dataType >
DSPLIB_STATUS DSPLIB_bexp_init_ci (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 This function is the initialization function for the C7x implementation of the kernel. The function declaration conforms to the declaration of DSPLIB_bexp_init. More...
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< int8_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint8_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< int16_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint16_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< int32_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint32_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< int64_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint64_t > (DSPLIB_kernelHandle handle, const DSPLIB_bufParams1D_t *bufParamsIn, const DSPLIB_bufParams1D_t *bufParamsOut, const DSPLIB_bexp_InitArgs *pKerInitArgs)
 
template<typename UnsignedDataType >
void bexp_exec_ci_unsigned_small_inputs (void *restrict pIn, void *restrict pOut, uint8_t *restrict pBlock, int32_t mainLoopCount)
 
template<typename SignedDataType >
void bexp_exec_ci_signed_small_inputs (void *restrict pIn, void *restrict pOut, uint8_t *restrict pBlock, int32_t mainLoopCount)
 
template<typename UnsignedDataType >
void bexp_exec_ci_unsigned (void *restrict pOut, uint32_t mainLoopCount)
 
template<typename SignedDataType >
void bexp_exec_ci_signed (void *restrict pOut, uint32_t mainLoopCount)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int8_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint8_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int16_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint16_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int32_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint32_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int64_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 
template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint64_t > (DSPLIB_kernelHandle handle, void *restrict pIn, void *restrict pOut)
 

Macro Definition Documentation

◆ SE_PARAM_BASE

#define SE_PARAM_BASE   (0x0000)

Definition at line 53 of file DSPLIB_bexp_ci.cpp.

◆ SE_SE0_PARAM_OFFSET

#define SE_SE0_PARAM_OFFSET   (SE_PARAM_BASE)

Definition at line 54 of file DSPLIB_bexp_ci.cpp.

◆ SE_SE1_PARAM_OFFSET

#define SE_SE1_PARAM_OFFSET   (SE_SE0_PARAM_OFFSET + SE_PARAM_SIZE)

Definition at line 55 of file DSPLIB_bexp_ci.cpp.

◆ LAST_VEC_AND_MASK_OFFSET

#define LAST_VEC_AND_MASK_OFFSET   (SE_PARAM_BASE)

Definition at line 56 of file DSPLIB_bexp_ci.cpp.

Function Documentation

◆ DSPLIB_bexp_init_ci()

template<typename dataType >
DSPLIB_STATUS DSPLIB_bexp_init_ci ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

This function is the initialization function for the C7x implementation of the kernel. The function declaration conforms to the declaration of DSPLIB_bexp_init.

Init function of the bexp kernel to setup the SE

Definition at line 62 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_init_ci< int8_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< int8_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ DSPLIB_bexp_init_ci< uint8_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint8_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ DSPLIB_bexp_init_ci< int16_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< int16_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ DSPLIB_bexp_init_ci< uint16_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint16_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ DSPLIB_bexp_init_ci< int32_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< int32_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ DSPLIB_bexp_init_ci< uint32_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint32_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ DSPLIB_bexp_init_ci< int64_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< int64_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ DSPLIB_bexp_init_ci< uint64_t >()

template DSPLIB_STATUS DSPLIB_bexp_init_ci< uint64_t > ( DSPLIB_kernelHandle  handle,
const DSPLIB_bufParams1D_t bufParamsIn,
const DSPLIB_bufParams1D_t bufParamsOut,
const DSPLIB_bexp_InitArgs pKerInitArgs 
)

◆ bexp_exec_ci_unsigned_small_inputs()

template<typename UnsignedDataType >
void bexp_exec_ci_unsigned_small_inputs ( void *restrict  pIn,
void *restrict  pOut,
uint8_t *restrict  pBlock,
int32_t  mainLoopCount 
)
inline

Templated implementation of the bexp kernel to handle unsigned and signed data types differently

Check the last bit and if it is 1, return 0 else, return norm + 1

Definition at line 170 of file DSPLIB_bexp_ci.cpp.

◆ bexp_exec_ci_signed_small_inputs()

template<typename SignedDataType >
void bexp_exec_ci_signed_small_inputs ( void *restrict  pIn,
void *restrict  pOut,
uint8_t *restrict  pBlock,
int32_t  mainLoopCount 
)
inline

Definition at line 211 of file DSPLIB_bexp_ci.cpp.

◆ bexp_exec_ci_unsigned()

template<typename UnsignedDataType >
void bexp_exec_ci_unsigned ( void *restrict  pOut,
uint32_t  mainLoopCount 
)
inline

Check the last bit and if it is 1, return 0 else, return norm + 1

Definition at line 242 of file DSPLIB_bexp_ci.cpp.

◆ bexp_exec_ci_signed()

template<typename SignedDataType >
void bexp_exec_ci_signed ( void *restrict  pOut,
uint32_t  mainLoopCount 
)
inline

Definition at line 280 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< int8_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int8_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Exec function of the bexp kernel

Definition at line 313 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< uint8_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint8_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Definition at line 344 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< int16_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int16_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Definition at line 374 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< uint16_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint16_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Definition at line 404 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< int32_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int32_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Definition at line 434 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< uint32_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint32_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Definition at line 464 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< int64_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< int64_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Definition at line 494 of file DSPLIB_bexp_ci.cpp.

◆ DSPLIB_bexp_exec_ci< uint64_t >()

template<>
DSPLIB_STATUS DSPLIB_bexp_exec_ci< uint64_t > ( DSPLIB_kernelHandle  handle,
void *restrict  pIn,
void *restrict  pOut 
)

Definition at line 524 of file DSPLIB_bexp_ci.cpp.