instruction
stringlengths
139
357k
response
stringlengths
36
4.54k
buggy_type
stringclasses
745 values
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS arr...
The wrong part of the code is: #pragma HLS array_partition variable=o complete The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'FND'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS array_pa...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'FND'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS array_partition variable=o complete The high-level-synthesis bug type of the code is: 'FND'
'FND'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS array_partition variable=o complete The high-level-synthesis bug type of the code is: 'FND' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'FND'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS arr...
The wrong part of the code is: #pragma HLS array_partition variable=o dim=2 The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'DID'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS array_pa...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'DID'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS array_partition variable=o dim=2 The high-level-synthesis bug type of the code is: 'DID'
'DID'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS array_partition variable=o dim=2 The high-level-synthesis bug type of the code is: 'DID' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'DID'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS dat...
The wrong part of the code is: #pragma HLS dataflow The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'DFP'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS dataflow...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'DFP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS dataflow The high-level-synthesis bug type of the code is: 'DFP'
'DFP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS dataflow The high-level-synthesis bug type of the code is: 'DFP' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'DFP'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS int...
The wrong part of the code is: #pragma HLS interface s_axilite port=o The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'IDAP'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS interfac...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'IDAP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS interface s_axilite port=o The high-level-synthesis bug type of the code is: 'IDAP'
'IDAP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS interface s_axilite port=o The high-level-synthesis bug type of the code is: 'IDAP' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'IDAP'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS int...
The wrong part of the code is: #pragma HLS interface m_axi port=o The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'RAMB'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS interfac...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'RAMB'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS interface m_axi port=o The high-level-synthesis bug type of the code is: 'RAMB'
'RAMB'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS interface m_axi port=o The high-level-synthesis bug type of the code is: 'RAMB' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'RAMB'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS int...
The wrong part of the code is: #pragma HLS interface ap_memory port=o The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'SMA'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS interfac...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'SMA'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS interface ap_memory port=o The high-level-synthesis bug type of the code is: 'SMA'
'SMA'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS interface ap_memory port=o The high-level-synthesis bug type of the code is: 'SMA' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'SMA'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS int...
The wrong part of the code is: #pragma HLS interface ap_vld port=o The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'AMS'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS interfac...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'AMS'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS interface ap_vld port=o The high-level-synthesis bug type of the code is: 'AMS'
'AMS'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS interface ap_vld port=o The high-level-synthesis bug type of the code is: 'AMS' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'AMS'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS pip...
The wrong part of the code is: #pragma HLS pipeline II=2 The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'MLP'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS pipeline...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'MLP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS pipeline II=2 The high-level-synthesis bug type of the code is: 'MLP'
'MLP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS pipeline II=2 The high-level-synthesis bug type of the code is: 'MLP' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'MLP'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS unr...
The wrong part of the code is: #pragma HLS unroll factor=2 The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'ILNU'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pragma HLS unroll f...
The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'ILNU'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma HLS INTERFACE ap_none port=o #pra...
The wrong part of the code is: #pragma HLS unroll factor=2 The high-level-synthesis bug type of the code is: 'ILNU'
'ILNU'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ```c++ #include <ap_int.h> void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) { #pragma HLS INTERFACE ap_none port=i #pragma H...
The wrong part of the code is: #pragma HLS unroll factor=2 The high-level-synthesis bug type of the code is: 'ILNU' The right code snippet is: o = (i.range(30, 0), i.range(31, 31));
'ILNU'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: q = SRL_SIG[a+1]; The right code snippet is: q = SRL_SIG[a];
'OOB'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: q = SRL_SIG[a];
'OOB'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: q = SRL_SIG[a+1]; The high-level-synthesis bug type of the code is: 'OOB'
'OOB'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: q = SRL_SIG[a+1]; The high-level-synthesis bug type of the code is: 'OOB' The right code snippet is: q = SRL_SIG[a];
'OOB'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: ap_uint<DATA_WIDTH> SRL_SIG[DEPTH]; The right code snippet is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH];
'INIT'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH];
'INIT'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: ap_uint<DATA_WIDTH> SRL_SIG[DEPTH]; The high-level-synthesis bug type of the code is: 'INIT'
'INIT'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: ap_uint<DATA_WIDTH> SRL_SIG[DEPTH]; The high-level-synthesis bug type of the code is: 'INIT' The right code snippet is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH];
'INIT'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: SRL_SIG[i] = SRL_SIG[i-2] << 20; The right code snippet is: SRL_SIG[i] = SRL_SIG[i-1];
'SHFT'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: SRL_SIG[i] = SRL_SIG[i-1];
'SHFT'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: SRL_SIG[i] = SRL_SIG[i-2] << 20; The high-level-synthesis bug type of the code is: 'SHFT'
'SHFT'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: SRL_SIG[i] = SRL_SIG[i-2] << 20; The high-level-synthesis bug type of the code is: 'SHFT' The right code snippet is: SRL_SIG[i] = SRL_SIG[i-1];
'SHFT'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: for (int i = DEPTH-1; i >= 0; i--) { The right code snippet is: for (int i = DEPTH-1; i > 0; i--) {
'INF'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: for (int i = DEPTH-1; i > 0; i--) {
'INF'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: for (int i = DEPTH-1; i >= 0; i--) { The high-level-synthesis bug type of the code is: 'INF'
'INF'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: for (int i = DEPTH-1; i >= 0; i--) { The high-level-synthesis bug type of the code is: 'INF' The right code snippet is: for (int i = DEPTH-1; i > 0; i--) {
'INF'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: int& q The right code snippet is: ap_uint<DATA_WIDTH>& q
'USE'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: ap_uint<DATA_WIDTH>& q
'USE'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: int& q The high-level-synthesis bug type of the code is: 'USE'
'USE'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: int& q The high-level-synthesis bug type of the code is: 'USE' The right code snippet is: ap_uint<DATA_WIDTH>& q
'USE'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: SRL_SIG[0] = data; SRL_SIG[1] = data; SRL_SIG[2] = data; The right code snippet is: for (int i = DEPTH-1; i > 0; i--) {
'MLU'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: for (int i = DEPTH-1; i > 0; i--) {
'MLU'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: SRL_SIG[0] = data; SRL_SIG[1] = data; SRL_SIG[2] = data; The high-level-synthesis bug type of the code is: 'MLU'
'MLU'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: SRL_SIG[0] = data; SRL_SIG[1] = data; SRL_SIG[2] = data; The high-level-synthesis bug type of the code is: 'MLU' The right code snippet is: for (int i = DEPTH-1; i > 0; i--) {
'MLU'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH] = {0}; The right code snippet is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH];
'ZERO'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH];
'ZERO'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH] = {0}; The high-level-synthesis bug type of the code is: 'ZERO'
'ZERO'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH] = {0}; The high-level-synthesis bug type of the code is: 'ZERO' The right code snippet is: static ap_uint<DATA_WIDTH> SRL_SIG[DEPTH];
'ZERO'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: q = SRL_SIG[a+DEPTH]; The right code snippet is: q = SRL_SIG[a];
'BUF'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: q = SRL_SIG[a];
'BUF'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: q = SRL_SIG[a+DEPTH]; The high-level-synthesis bug type of the code is: 'BUF'
'BUF'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: q = SRL_SIG[a+DEPTH]; The high-level-synthesis bug type of the code is: 'BUF' The right code snippet is: q = SRL_SIG[a];
'BUF'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG cyclic dim=1 The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'APT'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'APT'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG cyclic dim=1 The high-level-synthesis bug type of the code is: 'APT'
'APT'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG cyclic dim=1 The high-level-synthesis bug type of the code is: 'APT' The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'APT'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG complete dim=2 The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'FND'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'FND'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG complete dim=2 The high-level-synthesis bug type of the code is: 'FND'
'FND'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG complete dim=2 The high-level-synthesis bug type of the code is: 'FND' The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'FND'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG complete dim=3 The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'DID'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'DID'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG complete dim=3 The high-level-synthesis bug type of the code is: 'DID'
'DID'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS array_partition variable=SRL_SIG complete dim=3 The high-level-synthesis bug type of the code is: 'DID' The right code snippet is: #pragma HLS array_partition variable=SRL_SIG complete dim=1
'DID'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS dataflow pipeline II=2 The right code snippet is: #pragma HLS dataflow
'DFP'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS dataflow
'DFP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS dataflow pipeline II=2 The high-level-synthesis bug type of the code is: 'DFP'
'DFP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS dataflow pipeline II=2 The high-level-synthesis bug type of the code is: 'DFP' The right code snippet is: #pragma HLS dataflow
'DFP'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS interface ap_none port=return The right code snippet is: #pragma HLS interface ap_ctrl_none port=return
'IDAP'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS interface ap_ctrl_none port=return
'IDAP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS interface ap_none port=return The high-level-synthesis bug type of the code is: 'IDAP'
'IDAP'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS interface ap_none port=return The high-level-synthesis bug type of the code is: 'IDAP' The right code snippet is: #pragma HLS interface ap_ctrl_none port=return
'IDAP'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS interface m_axi port=img_rows bundle=AXI_MASTER The right code snippet is: #pragma HLS interface m_axi port=img_rows bundle=AXI_SLAVE
'RAMB'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS interface m_axi port=img_rows bundle=AXI_SLAVE
'RAMB'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS interface m_axi port=img_rows bundle=AXI_MASTER The high-level-synthesis bug type of the code is: 'RAMB'
'RAMB'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS interface m_axi port=img_rows bundle=AXI_MASTER The high-level-synthesis bug type of the code is: 'RAMB' The right code snippet is: #pragma HLS interface m_axi port=img_rows bundle=AXI_SLAVE
'RAMB'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS interface bram port=img_rows The right code snippet is: #pragma HLS interface ap_fifo port=img_rows
'SMA'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS interface ap_fifo port=img_rows
'SMA'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS interface bram port=img_rows The high-level-synthesis bug type of the code is: 'SMA'
'SMA'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS interface bram port=img_rows The high-level-synthesis bug type of the code is: 'SMA' The right code snippet is: #pragma HLS interface ap_fifo port=img_rows
'SMA'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap...
The wrong part of the code is: #pragma HLS interface ap_fifo port=img_rows The right code snippet is: #pragma HLS interface bram port=img_rows
'AMS'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, const ap_uint...
The right code snippet is: #pragma HLS interface bram port=img_rows
'AMS'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_channel_shiftReg( const ap_clk& clk, ...
The wrong part of the code is: #pragma HLS interface ap_fifo port=img_rows The high-level-synthesis bug type of the code is: 'AMS'
'AMS'
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet The buggy code is: ``` #include <ap_int.h> const int DATA_WIDTH = 12; const int ADDR_WIDTH = 2; const int DEPTH = 3; void FIFO_pixelq_op_img_rows_V_chann...
The wrong part of the code is: #pragma HLS interface ap_fifo port=img_rows The high-level-synthesis bug type of the code is: 'AMS' The right code snippet is: #pragma HLS interface bram port=img_rows
'AMS'