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_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE ap_none port=ENCLK bool ENCLK_reg; void SNPS_...
The wrong part of the code is: ENCLK = (int)ENCLK_reg; The right code snippet is: ENCLK = ENCLK_reg;
'USE'
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_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE ap_none port=ENCLK bool ENCLK_reg; void SNPS_CLOCK...
The right code snippet is: ENCLK = ENCLK_reg;
'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: #pragma HLS INTERFACE ap_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE ap_none port=ENCLK bool ENCLK_reg; ...
The wrong part of the code is: ENCLK = (int)ENCLK_reg; 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: #pragma HLS INTERFACE ap_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE...
The wrong part of the code is: ENCLK = (int)ENCLK_reg; The high-level-synthesis bug type of the code is: 'USE' The right code snippet is: ENCLK = ENCLK_reg;
'USE'
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_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE ap_none port=ENCLK bool ENCLK_reg; void SNPS_...
The wrong part of the code is: if (EN && TE) { ENCLK_reg = true; } else { #pragma HLS unroll ENCLK_reg = false; } ENCLK = ENCLK_reg; The right code snippet is: if (EN && TE) { ENCLK_reg = true; } else { ENCLK_reg = false; } ENCLK = ENCLK_r...
'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_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE ap_none port=ENCLK bool ENCLK_reg; void SNPS_CLOCK...
The right code snippet is: if (EN && TE) { ENCLK_reg = true; } else { ENCLK_reg = false; } ENCLK = ENCLK_reg;
'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_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE ap_none port=ENCLK bool ENCLK_reg; ...
The wrong part of the code is: if (EN && TE) { ENCLK_reg = true; } else { #pragma HLS unroll ENCLK_reg = false; } ENCLK = ENCLK_reg; 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_none port=CLK #pragma HLS INTERFACE ap_none port=EN #pragma HLS INTERFACE ap_none port=TE #pragma HLS INTERFACE...
The wrong part of the code is: if (EN && TE) { ENCLK_reg = true; } else { #pragma HLS unroll ENCLK_reg = false; } ENCLK = ENCLK_reg; The high-level-synthesis bug type of the code is: 'ILNU' The right code snippet is: if (EN && TE) { ENCLK_reg = true; ...
'ILNU'
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: mux_2to1(in+i*3, sel_2to1[i], mux_2to1_out[i]); The right code snippet is: mux_2to1(in+i*2, sel_2to1[i], mux_2to1_out[i]);
OOB
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: mux_2to1(in+i*2, sel_2to1[i], mux_2to1_out[i]);
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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: mux_2to1(in+i*3, sel_2to1[i], mux_2to1_out[i]); 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: mux_2to1(in+i*3, sel_2to1[i], mux_2to1_out[i]); The high-level-synthesis bug type of the code is: OOB The right code snippet is: mux_2to1(in+i*2, sel_2to1[i], mux_2to1_out[i]);
OOB
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: int sel_8to1[2] = {0}; The right code snippet is: int sel_8to1[2];
INIT
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: int sel_8to1[2];
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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: int sel_8to1[2] = {0}; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: int sel_8to1[2] = {0}; The high-level-synthesis bug type of the code is: INIT The right code snippet is: int sel_8to1[2];
INIT
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: sel_8to1[0] = (sel[2] << 2) | (sel[1] << 1) | (sel[0] << 0); The right code snippet is: sel_8to1[0] = (sel[2] << 1) | (sel[1] << 0) | (sel[0] << 0);
SHFT
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: sel_8to1[0] = (sel[2] << 1) | (sel[1] << 0) | (sel[0] << 0);
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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: sel_8to1[0] = (sel[2] << 2) | (sel[1] << 1) | (sel[0] << 0); 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: sel_8to1[0] = (sel[2] << 2) | (sel[1] << 1) | (sel[0] << 0); The high-level-synthesis bug type of the code is: SHFT The right code snippet is: sel_8to1[0] = (sel[2] << 1) | (sel[1] << 0) | (sel[0] << 0);
SHFT
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: for(int i=0; i>=0; i++) { The right code snippet is: for(int i=0; i<2; i++) {
INF
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: for(int i=0; i<2; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: for(int i=0; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: for(int i=0; i>=0; i++) { The high-level-synthesis bug type of the code is: INF The right code snippet is: for(int i=0; i<2; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: unsigned int sel_8to1[2]; The right code snippet is: int sel_8to1[2];
USE
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: int sel_8to1[2];
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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: unsigned int sel_8to1[2]; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: unsigned int sel_8to1[2]; The high-level-synthesis bug type of the code is: USE The right code snippet is: int sel_8to1[2];
USE
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: for(int i=0; i<3; i++) { The right code snippet is: for(int i=0; i<2; i++) {
MLU
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: for(int i=0; i<2; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: for(int i=0; i<3; i++) { 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: for(int i=0; i<3; i++) { The high-level-synthesis bug type of the code is: MLU The right code snippet is: for(int i=0; i<2; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: int sel_8to1[2] = {}; The right code snippet is: int sel_8to1[2];
ZERO
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: int sel_8to1[2];
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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: int sel_8to1[2] = {}; 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: int sel_8to1[2] = {}; The high-level-synthesis bug type of the code is: ZERO The right code snippet is: int sel_8to1[2];
ZERO
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: mux_8to1(in+i*4, sel_8to1, mux_8to1_out[i]); The right code snippet is: mux_8to1(in+i*8, sel_8to1, mux_8to1_out[i]);
BUF
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: mux_8to1(in+i*8, sel_8to1, mux_8to1_out[i]);
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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: mux_8to1(in+i*4, sel_8to1, mux_8to1_out[i]); 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: mux_8to1(in+i*4, sel_8to1, mux_8to1_out[i]); The high-level-synthesis bug type of the code is: BUF The right code snippet is: mux_8to1(in+i*8, sel_8to1, mux_8to1_out[i]);
BUF
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 cyclic dim=1 The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 cyclic dim=1 The high-level-synthesis bug type of the code is: APT The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 cyclic dim=2 The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 cyclic 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 cyclic dim=2 The high-level-synthesis bug type of the code is: FND The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 complete dim=2 The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 complete 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 complete dim=2 The high-level-synthesis bug type of the code is: DID The right code snippet is: #pragma HLS ARRAY_PARTITION variable=sel_8to1 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: #pragma HLS INTERFACE ap_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: #pragma HLS DATAFLOW off 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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: #pragma HLS DATAFLOW off 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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: #pragma HLS DATAFLOW off 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_vld port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fal...
The wrong part of the code is: #pragma HLS INTERFACE ap_vld port=in The right code snippet is: #pragma HLS INTERFACE ap_none port=in
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_vld port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ?...
The right code snippet is: #pragma HLS INTERFACE ap_none port=in
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_vld port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = ...
The wrong part of the code is: #pragma HLS INTERFACE ap_vld port=in 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_vld port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in...
The wrong part of the code is: #pragma HLS INTERFACE ap_vld port=in The high-level-synthesis bug type of the code is: IDAP The right code snippet is: #pragma HLS INTERFACE ap_none port=in
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: #pragma HLS INTERFACE s_axilite port=in The right code snippet is: #pragma HLS INTERFACE m_axi port=in
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: #pragma HLS INTERFACE m_axi port=in
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: #pragma HLS INTERFACE s_axilite port=in 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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: #pragma HLS INTERFACE s_axilite port=in The high-level-synthesis bug type of the code is: RAMB The right code snippet is: #pragma HLS INTERFACE m_axi port=in
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 bram port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false...
The wrong part of the code is: #pragma HLS INTERFACE bram port=in The right code snippet is: #pragma HLS INTERFACE ap_none port=in
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 bram port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ? i...
The right code snippet is: #pragma HLS INTERFACE ap_none port=in
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 bram port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (s...
The wrong part of the code is: #pragma HLS INTERFACE bram port=in 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 bram port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2...
The wrong part of the code is: #pragma HLS INTERFACE bram port=in The high-level-synthesis bug type of the code is: SMA The right code snippet is: #pragma HLS INTERFACE ap_none port=in
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: #pragma HLS INTERFACE ap_none port=in The right code snippet is: #pragma HLS INTERFACE ap_vld port=in
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: #pragma HLS INTERFACE ap_vld port=in
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: #pragma HLS INTERFACE ap_none port=in 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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: #pragma HLS INTERFACE ap_none port=in The high-level-synthesis bug type of the code is: AMS The right code snippet is: #pragma HLS INTERFACE ap_vld port=in
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == fa...
The wrong part of the code is: #pragma HLS UNROLL factor=1 The right code snippet is: #pragma HLS UNROLL factor=2
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out = (sel == false) ...
The right code snippet is: #pragma HLS UNROLL factor=2
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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int in[2], bool sel, int& out) { out =...
The wrong part of the code is: #pragma HLS UNROLL factor=1 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_none port=in #pragma HLS INTERFACE ap_none port=sel #pragma HLS INTERFACE ap_none port=out void mux_2to1(int i...
The wrong part of the code is: #pragma HLS UNROLL factor=1 The high-level-synthesis bug type of the code is: ILNU The right code snippet is: #pragma HLS UNROLL factor=2
ILNU
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024];...
The wrong part of the code is: douta = mem[addra+1]; The right code snippet is: douta = mem[addra];
'OOB'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024]; voi...
The right code snippet is: douta = mem[addra];
'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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int...
The wrong part of the code is: douta = mem[addra+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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma ...
The wrong part of the code is: douta = mem[addra+1]; The high-level-synthesis bug type of the code is: 'OOB' The right code snippet is: douta = mem[addra];
'OOB'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024] ...
The wrong part of the code is: int mem[1024] = {0}; The right code snippet is: int mem[1024];
'INIT'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024] = {0}...
The right code snippet is: int mem[1024];
'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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int...
The wrong part of the code is: int mem[1024] = {0}; 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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma ...
The wrong part of the code is: int mem[1024] = {0}; The high-level-synthesis bug type of the code is: 'INIT' The right code snippet is: int mem[1024];
'INIT'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024];...
The wrong part of the code is: douta = mem[addra << 10]; The right code snippet is: douta = mem[addra];
'SHFT'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024]; voi...
The right code snippet is: douta = mem[addra];
'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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int...
The wrong part of the code is: douta = mem[addra << 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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma ...
The wrong part of the code is: douta = mem[addra << 10]; The high-level-synthesis bug type of the code is: 'SHFT' The right code snippet is: douta = mem[addra];
'SHFT'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024];...
The wrong part of the code is: void Initial_blk_mem_gen_prim_width__parameterized20(int& douta, bool clka, int addra) { #pragma HLS PIPELINE II=1 while(true){ douta = mem[addra]; mem[addra] = douta; } } The right code snippet is: void Initial_blk_mem_gen_prim_width__paramete...
'INF'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int mem[1024]; voi...
The right code snippet is: void Initial_blk_mem_gen_prim_width__parameterized20(int& douta, bool clka, int addra) { #pragma HLS PIPELINE II=1 douta = mem[addra]; mem[addra] = douta; }
'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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta int...
The wrong part of the code is: void Initial_blk_mem_gen_prim_width__parameterized20(int& douta, bool clka, int addra) { #pragma HLS PIPELINE II=1 while(true){ douta = mem[addra]; mem[addra] = douta; } } 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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma ...
The wrong part of the code is: void Initial_blk_mem_gen_prim_width__parameterized20(int& douta, bool clka, int addra) { #pragma HLS PIPELINE II=1 while(true){ douta = mem[addra]; mem[addra] = douta; } } The high-level-synthesis bug type of the code is: 'INF' The right code s...
'INF'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta unsigned int m...
The wrong part of the code is: unsigned int mem[1024]; The right code snippet is: int mem[1024];
'USE'
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_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta unsigned int mem[10...
The right code snippet is: int mem[1024];
'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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma HLS INTERFACE ap_fifo port=douta uns...
The wrong part of the code is: unsigned int mem[1024]; 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: #pragma HLS INTERFACE ap_none port=clka #pragma HLS INTERFACE ap_none port=addra #pragma HLS INTERFACE ap_ctrl_none port=return #pragma ...
The wrong part of the code is: unsigned int mem[1024]; The high-level-synthesis bug type of the code is: 'USE' The right code snippet is: int mem[1024];
'USE'