DP-HLS
 All Classes Namespaces Files Functions Variables Typedefs Macros Pages
utils.h File Reference
#include "params.h"
#include <string>

Go to the source code of this file.

Namespaces

 Utils
 
 Utils::Array
 
 Utils::Init
 
 Utils::Matrix
 
 Utils::Kernel
 

Functions

template<typename T , int N>
void Utils::Array::ShiftLeft (T(&arr)[N], T new_data)
 
template<typename T , int N>
void Utils::Array::ShiftRight (T(&arr)[N], T new_data)
 
template<typename T , int M, int N, int LEN>
void Utils::Array::Copy (T(&src)[M], T(&dst)[N], idx_t len, T default_num)
 Copy length LEN of data from src to dst. If more than len, fill the rest with default_num. We need to use fixed length array rather than a pointer is because HLS is not pointer friendly. More...
 
template<typename T , int N>
void Utils::Array::Copy (T(&src)[N], T(&dst)[N])
 
template<typename T >
void Utils::Array::Switch (T **arr1, T **arr2)
 
template<typename T , int LEN>
void Utils::Array::Linspace (T(&arr)[LEN], T start, T step)
 
template<typename T , int N>
void Utils::Init::ArrSet (T(&arr)[N], T val)
 
template<typename T , int N>
void Utils::Init::ArrSet (T(&arr)[N], idx_t layer, T val)
 
template<typename T , int LAY, int N>
void Utils::Init::Linspace (hls::vector< T, LAY >(&arr)[N], idx_t starting_idx, idx_t layer, type_t start, type_t step)
 
template<typename T >
void Utils::Init::Linspace (T &arr, idx_t starting_idx, idx_t layer, type_t start, type_t step, int len)
 
template<typename PACK , typename IDX_T , int LEN>
void Utils::Init::DetermineGlobalTracebackCoordinate (PACK(&local_maximum)[LEN], IDX_T qry_len, IDX_T ref_len)
 ONLY FOR RECTANGULAR KERNEL Global alignment start the traceback at the bottom right corner of the score matrix. Given the query and reference length, the traceback physical address can be determined before the score matri iteration. Thus, this function takes the ScorePack array, according to the query and reference legnth, to set the traceback starting PE's ScorePack with INF and corresponding coordinate. More...
 
template<typename PACK , typename IDX_T , int PE_NUM_, int BANDWIDTH_, int TB_CHUNK_WIDTH_>
void Utils::Init::DetermineFixedBandingGlobalTracebackCoordinate (PACK(&max)[PE_NUM_], IDX_T qry_len, IDX_T ref_len)
 
template<typename T , int LEN, int BLK>
void Utils::Kernel::top_level_radin_line (T src[BLK], T dst[BLK][LEN], idx_t i)
 
template<typename T , int LEN, int BLK>
void Utils::Kernel::top_level_readin (T ddr_in[LEN][BLK], T internal[BLK][LEN])
 
template<typename T , int LEN, int BLK>
void Utils::Kernel::top_level_writeout (T internal[BLK][LEN], T ddr_out[LEN][BLK])