Skip to content

Commit

Permalink
cleaned repository
Browse files Browse the repository at this point in the history
  • Loading branch information
Cloud User committed Jun 3, 2024
1 parent 98ea266 commit 18c714e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 49 deletions.
46 changes: 1 addition & 45 deletions include/traceback.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,15 +115,6 @@ namespace Traceback
int ck_idx, int pe_idx, int col_idx, int v_row, int v_col)
{

#ifdef CMAKEDEBUG
// set the initial state of the traceback to be AL_END
for (int i = 0; i < MAX_QUERY_LENGTH + MAX_REFERENCE_LENGTH; i++)
{
traceback_out[i] = AL_END;
}
#endif

#pragma HLS bind_storage variable = traceback_out type = fifo impl = uram
int pe = pe_idx; // row index, but in tbmat
int col = col_idx;
int chunk = ck_idx;
Expand All @@ -134,46 +125,12 @@ namespace Traceback
TB_STATE state;
ALIGN_TYPE::Traceback::StateInit(tbmat[pe][col], state);

#ifdef CMAKEDEBUG
// print the content fo tbmat
// Please print it with certain width for the first row, which is the index

for (int j = 0; j < TBMEM_SIZE; j++)
{
std::cout << std::setw(3) << j << " ";
}
std::cout << std::endl;
for (int i = 0; i < PE_NUM; i++)
{
for (int j = 0; j < TBMEM_SIZE; j++)
{
std::cout << std::setw(3) << tbmat[i][j].to_int() << " ";
}
std::cout << std::endl;
}
std::cout << std::endl;
#endif

traceback_loop:
TracebackLoop:
while (navigation != AL_END) // Now solely this flag determines whether to stop the traceback.
{
#pragma HLS PIPELINE II = 1

#ifdef CMAKEDEBUG
// Print Coordinates
// printf("Traceback Current Coordinates: pe %d, col %d, chunk %d\n", pe, col, chunk);
#endif
tbp_t tbptr = tbmat[pe][col]; // Want to represented by the symbol rather than pointer
#ifdef CMAKEDEBUG
// print traceback pionter
// std::cout << tbptr.to_int() << " ";
// printf("navigation %d, pointer: %d\n", navigation.to_int(), tbptr.to_int());
#endif

#ifdef CMAKEDEBUG
// print virtual row and column number
// printf("Traceback Coordinates: ck %d, pe %d, p_col %d, row %d, col %d\n", chunk, pe, col, pe + chunk * PE_NUM, col % TEST_REFERENCE_LENGTH);
#endif

// User define mapping from a pointer and current state to
// one of the Del, Ins, Match/Mismatch, or End to the next state.
Expand All @@ -182,7 +139,6 @@ namespace Traceback
Traceback::NextAddressFixedSize<CHUNK_WIDTH>(navigation, chunk, pe, col, v_row, v_col);
}
traceback_out[w_id] = AL_END;
// std::cout << std::endl;
}

/**
Expand Down
2 changes: 0 additions & 2 deletions py-hls/auto_cosim.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,5 +124,3 @@ def read_config_file(config_file_path):
for cmd in cmds:
print(f"Executing command: {cmd}")
os.system(cmd)


4 changes: 2 additions & 2 deletions testbench/test_csim_global_two_piece_affine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@

using namespace std;

#define INPUT_QUERY_LENGTH 127
#define INPUT_REFERENCE_LENGTH 128
#define INPUT_QUERY_LENGTH 256
#define INPUT_REFERENCE_LENGTH 256

char_t base_to_num(char base)
{
Expand Down

0 comments on commit 18c714e

Please sign in to comment.