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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_ax...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel cyclic dim=0 The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'APT'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite...
The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INT...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel cyclic dim=0 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite por...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel cyclic dim=0 The high-level-synthesis bug type of the code is: 'APT' The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'APT'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_ax...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel complete factor=2 dim=0 The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'FND'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite...
The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INT...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel complete factor=2 dim=0 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite por...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel complete factor=2 dim=0 The high-level-synthesis bug type of the code is: 'FND' The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'FND'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_ax...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=1 The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'DID'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite...
The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INT...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=1 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite por...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=1 The high-level-synthesis bug type of the code is: 'DID' The right code snippet is: #pragma HLS ARRAY_PARTITION variable=read_sel complete dim=0
'DID'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_ax...
The wrong part of the code is: #pragma HLS DATAFLOW 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite...
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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INT...
The wrong part of the code is: #pragma HLS DATAFLOW 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite por...
The wrong part of the code is: #pragma HLS DATAFLOW 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilit...
The wrong part of the code is: #pragma HLS INTERFACE m_axi port=data bundle=CTRL The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'IDAP'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite por...
The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFA...
The wrong part of the code is: #pragma HLS INTERFACE m_axi port=data bundle=CTRL 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=co...
The wrong part of the code is: #pragma HLS INTERFACE m_axi port=data bundle=CTRL The high-level-synthesis bug type of the code is: 'IDAP' The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'IDAP'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data depth=2048 bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFA...
The wrong part of the code is: #pragma HLS INTERFACE m_axi port=data depth=2048 bundle=CTRL The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'RAMB'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data depth=2048 bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_...
The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data depth=2048 bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma ...
The wrong part of the code is: #pragma HLS INTERFACE m_axi port=data depth=2048 bundle=CTRL 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE m_axi port=data depth=2048 bundle=CTRL #pragma HLS INTERFACE s_axil...
The wrong part of the code is: #pragma HLS INTERFACE m_axi port=data depth=2048 bundle=CTRL The high-level-synthesis bug type of the code is: 'RAMB' The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'RAMB'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE bram port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite...
The wrong part of the code is: #pragma HLS INTERFACE bram port=data bundle=CTRL The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'SMA'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE bram port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite port...
The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE bram port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFAC...
The wrong part of the code is: #pragma HLS INTERFACE bram port=data bundle=CTRL 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE bram port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=con...
The wrong part of the code is: #pragma HLS INTERFACE bram port=data bundle=CTRL The high-level-synthesis bug type of the code is: 'SMA' The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'SMA'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_none port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axil...
The wrong part of the code is: #pragma HLS INTERFACE ap_none port=data bundle=CTRL The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'AMS'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_none port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite p...
The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_none port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTER...
The wrong part of the code is: #pragma HLS INTERFACE ap_none port=data bundle=CTRL 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_none port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=...
The wrong part of the code is: #pragma HLS INTERFACE ap_none port=data bundle=CTRL The high-level-synthesis bug type of the code is: 'AMS' The right code snippet is: #pragma HLS INTERFACE s_axilite port=data bundle=CTRL
'AMS'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_ax...
The wrong part of the code is: #pragma HLS PIPELINE II=2 The right code snippet is: #pragma HLS PIPELINE II=1
'MLP'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite...
The right code snippet is: #pragma HLS PIPELINE II=1
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INT...
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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite por...
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: #pragma HLS PIPELINE II=1
'MLP'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_ax...
The wrong part of the code is: #pragma HLS UNROLL factor=4 The right code snippet is: #pragma HLS UNROLL factor=8
'ILNU'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INTERFACE s_axilite...
The right code snippet is: #pragma HLS UNROLL factor=8
'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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite port=control bundle=CTRL #pragma HLS INT...
The wrong part of the code is: #pragma HLS UNROLL factor=4 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: #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE s_axilite port=data bundle=CTRL #pragma HLS INTERFACE s_axilite por...
The wrong part of the code is: #pragma HLS UNROLL factor=4 The high-level-synthesis bug type of the code is: 'ILNU' The right code snippet is: #pragma HLS UNROLL factor=8
'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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: RESULT = A / 0; The right code snippet is: RESULT = A / B;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: RESULT = A / B;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: RESULT = A / 0; 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: RESULT = A / 0; The high-level-synthesis bug type of the code is: OOB The right code snippet is: RESULT = A / B;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: int x; RESULT = x; The right code snippet is: RESULT = 0;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: RESULT = 0;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: int x; RESULT = x; 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: int x; RESULT = x; The high-level-synthesis bug type of the code is: INIT The right code snippet is: RESULT = 0;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: RESULT = A << 10; The right code snippet is: RESULT = A << B;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: RESULT = A << B;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: RESULT = A << 10; 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: RESULT = A << 10; The high-level-synthesis bug type of the code is: SHFT The right code snippet is: RESULT = A << B;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: for (int i=0; i>=0; i++) { // some code } The right code snippet is: for (int i=0; i<10; i++) { // some code }
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: for (int i=0; i<10; i++) { // some code }
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: for (int i=0; i>=0; i++) { // some code } 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: for (int i=0; i>=0; i++) { // some code } The high-level-synthesis bug type of the code is: INF The right code snippet is: for (int i=0; i<10; i++) { // some code }
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: ap_uint<8> x = -1; The right code snippet is: ap_int<8> x = -1;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: ap_int<8> x = -1;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: ap_uint<8> x = -1; 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: ap_uint<8> x = -1; The high-level-synthesis bug type of the code is: USE The right code snippet is: ap_int<8> x = -1;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: for (int i=0; i<9; i++) { // some code } The right code snippet is: for (int i=0; i<10; i++) { // some code }
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: for (int i=0; i<10; i++) { // some code }
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: for (int i=0; i<9; i++) { // some code } 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: for (int i=0; i<9; i++) { // some code } The high-level-synthesis bug type of the code is: MLU The right code snippet is: for (int i=0; i<10; i++) { // some code }
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: ap_uint<4> A; The right code snippet is: ap_uint<4> A = 0;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: ap_uint<4> A = 0;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: ap_uint<4> A; 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: ap_uint<4> A; The high-level-synthesis bug type of the code is: ZERO The right code snippet is: ap_uint<4> A = 0;
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: memcpy(buffer1, buffer2+size, size); The right code snippet is: memcpy(buffer1, buffer2, size);
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: memcpy(buffer1, buffer2, size);
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: memcpy(buffer1, buffer2+size, size); 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: memcpy(buffer1, buffer2+size, size); The high-level-synthesis bug type of the code is: BUF The right code snippet is: memcpy(buffer1, buffer2, size);
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT block factor=2 dim=1 The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT block factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT block factor=2 dim=1 The high-level-synthesis bug type of the code is: APT The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT cyclic factor=3 dim=1 The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT cyclic factor=3 dim=1 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT cyclic factor=3 dim=1 The high-level-synthesis bug type of the code is: FND The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT cyclic factor=2 dim=2 The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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: #include <ap_int.h> const int NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: #pragma HLS array_partition variable=RESULT cyclic factor=2 dim=2 The high-level-synthesis bug type of the code is: DID The right code snippet is: #pragma HLS array_partition variable=RESULT cyclic factor=2 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: #pragma HLS dataflow loop_flatten 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: #pragma HLS dataflow loop_flatten 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: #pragma HLS dataflow loop_flatten 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: #pragma HLS interface m_axi port=buffer1 offset=1024 depth=1024 The right code snippet is: #pragma HLS interface m_axi port=buffer1 offset=slave depth=1024
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: #pragma HLS interface m_axi port=buffer1 offset=slave depth=1024
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: #pragma HLS interface m_axi port=buffer1 offset=1024 depth=1024 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: #pragma HLS interface m_axi port=buffer1 offset=1024 depth=1024 The high-level-synthesis bug type of the code is: RAMB The right code snippet is: #pragma HLS interface m_axi port=buffer1 offset=slave depth=1024
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESUL...
The wrong part of the code is: #pragma HLS interface ap_memory port=buffer1 The right code snippet is: #pragma HLS interface ap_fifo port=buffer1
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: RESULT = A...
The right code snippet is: #pragma HLS interface ap_fifo port=buffer1
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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { switch (OP) { case 0: ...
The wrong part of the code is: #pragma HLS interface ap_memory port=buffer1 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 NUM_OPERATIONS = 4; void calculator(ap_uint<4> A, ap_uint<4> B, ap_uint<2> OP, ap_uint<4> &RESULT) { ...
The wrong part of the code is: #pragma HLS interface ap_memory port=buffer1 The high-level-synthesis bug type of the code is: SMA The right code snippet is: #pragma HLS interface ap_fifo port=buffer1
SMA