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=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE ap_none po...
The wrong part of the code is: #pragma HLS array_partition variable=A1 complete dim=1 The right code snippet is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE ap_none port=Y ...
The right code snippet is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE...
The wrong part of the code is: #pragma HLS array_partition variable=A1 complete 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=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ...
The wrong part of the code is: #pragma HLS array_partition variable=A1 complete dim=1 The high-level-synthesis bug type of the code is: 'APT' The right code snippet is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE ap_none po...
The wrong part of the code is: #pragma HLS array_partition variable=A1 cyclic factor=3 dim=1 The right code snippet is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE ap_none port=Y ...
The right code snippet is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE...
The wrong part of the code is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ...
The wrong part of the code is: #pragma HLS array_partition variable=A1 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=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE ap_none po...
The wrong part of the code is: #pragma HLS array_partition variable=A1 cyclic factor=2 dim=2 The right code snippet is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE ap_none port=Y ...
The right code snippet is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ap_none port=B2 #pragma HLS INTERFACE...
The wrong part of the code is: #pragma HLS array_partition variable=A1 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: #pragma HLS INTERFACE ap_none port=A1 #pragma HLS INTERFACE ap_none port=A2 #pragma HLS INTERFACE ap_none port=B1 #pragma HLS INTERFACE ...
The wrong part of the code is: #pragma HLS array_partition variable=A1 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=A1 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: sineh = (e_to_x - e_to_neg_x) / 0.0f; The right code snippet is: sineh = (e_to_x - e_to_neg_x) / 2.0f;
'OOB'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: sineh = (e_to_x - e_to_neg_x) / 2.0f;
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: sineh = (e_to_x - e_to_neg_x) / 0.0f; 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: sineh = (e_to_x - e_to_neg_x) / 0.0f; The high-level-synthesis bug type of the code is: 'OOB' The right code snippet is: sineh = (e_to_x - e_to_neg_x) / 2.0f;
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x; float exp_neg_x = hls::exp(-x); float e_to_x = exp_x; f...
The wrong part of the code is: float exp_x; The right code snippet is: float exp_x = hls::exp(x);
'INIT'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x; float exp_neg_x = hls::exp(-x); float e_to_x = exp_x; float ...
The right code snippet is: float exp_x = hls::exp(x);
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x; float exp_neg_x = hls::exp(-x); float e_to_x = e...
The wrong part of the code is: float exp_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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x; float exp_neg_x...
The wrong part of the code is: float exp_x; The high-level-synthesis bug type of the code is: 'INIT' The right code snippet is: float exp_x = hls::exp(x);
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: cosh = (e_to_x + e_to_neg_x) << 2; The right code snippet is: cosh = (e_to_x + e_to_neg_x) / 2.0f;
'SHFT'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: cosh = (e_to_x + e_to_neg_x) / 2.0f;
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: cosh = (e_to_x + e_to_neg_x) << 2; 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: cosh = (e_to_x + e_to_neg_x) << 2; The high-level-synthesis bug type of the code is: 'SHFT' The right code snippet is: cosh = (e_to_x + e_to_neg_x) / 2.0f;
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { while(true){ float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); ...
The wrong part of the code is: void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { while(true){ The right code snippet is: void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) {
'INF'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { while(true){ float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); f...
The right code snippet is: void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) {
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { while(true){ float exp_x = hls::exp(x); float exp_neg_x = hls...
The wrong part of the code is: void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { while(true){ 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { while(true){ float exp_x = h...
The wrong part of the code is: void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { while(true){ The high-level-synthesis bug type of the code is: 'INF' The right code snippet is: void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) {
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); int e_to_x = ...
The wrong part of the code is: int e_to_x = exp_x; The right code snippet is: float e_to_x = exp_x;
'USE'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); int e_to_x = exp_x...
The right code snippet is: float e_to_x = exp_x;
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); in...
The wrong part of the code is: int e_to_x = exp_x; 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: int e_to_x = exp_x; The high-level-synthesis bug type of the code is: 'USE' The right code snippet is: float e_to_x = exp_x;
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: for(int i=0; i<10; i++){ sineh = (e_to_x - e_to_neg_x) / 2.0f; cosh = (e_to_x + e_to_neg_x) / 2.0f; tanh = sineh / cosh; } The right code snippet is: // No manual loop unrolling is used
'MLU'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: // No manual loop unrolling is used
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: for(int i=0; i<10; i++){ sineh = (e_to_x - e_to_neg_x) / 2.0f; cosh = (e_to_x + e_to_neg_x) / 2.0f; tanh = sineh / cosh; } 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: for(int i=0; i<10; i++){ sineh = (e_to_x - e_to_neg_x) / 2.0f; cosh = (e_to_x + e_to_neg_x) / 2.0f; tanh = sineh / cosh; } The high-level-synthesis bug type of the code is: 'MLU' The right code snippet is: // No manual loop unrolling is used
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: float e_to_x = 0; The right code snippet is: float e_to_x = hls::exp(x);
'ZERO'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: float e_to_x = hls::exp(x);
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: float e_to_x = 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: float e_to_x = 0; The high-level-synthesis bug type of the code is: 'ZERO' The right code snippet is: float e_to_x = hls::exp(x);
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: float exp_x = hls::exp(-x); float exp_neg_x = hls::exp(x); The right code snippet is: float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x);
'BUF'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x);
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: float exp_x = hls::exp(-x); float exp_neg_x = hls::exp(x); 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: float exp_x = hls::exp(-x); float exp_neg_x = hls::exp(x); The high-level-synthesis bug type of the code is: 'BUF' The right code snippet is: float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x);
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x block factor=2 dim=1 The right code snippet is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x 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=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x cyclic factor=3 dim=1 The right code snippet is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x 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=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x cyclic factor=2 dim=2 The right code snippet is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: #pragma HLS array_partition variable=exp_x 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=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: #pragma HLS dataflow wait(-1) 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: #pragma HLS dataflow wait(-1) 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: #pragma HLS dataflow wait(-1) 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: #pragma HLS interface m_axi port=exp_x offset=slave bundle=wrong_bundle The right code snippet is: #pragma HLS interface m_axi port=exp_x offset=slave bundle=gmem
'RAMB'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: #pragma HLS interface m_axi port=exp_x offset=slave bundle=gmem
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: #pragma HLS interface m_axi port=exp_x offset=slave bundle=wrong_bundle 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: #pragma HLS interface m_axi port=exp_x offset=slave bundle=wrong_bundle The high-level-synthesis bug type of the code is: 'RAMB' The right code snippet is: #pragma HLS interface m_axi port=exp_x offset=slave bundle=gmem
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: #pragma HLS interface s_axilite port=exp_x The right code snippet is: #pragma HLS interface bram port=exp_x
'SMA'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: #pragma HLS interface bram port=exp_x
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: #pragma HLS interface s_axilite port=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: #pragma HLS interface s_axilite port=exp_x The high-level-synthesis bug type of the code is: 'SMA' The right code snippet is: #pragma HLS interface bram port=exp_x
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: #pragma HLS interface s_axilite port=exp_x The right code snippet is: #pragma HLS interface ap_fifo port=exp_x
'AMS'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: #pragma HLS interface ap_fifo port=exp_x
'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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: #pragma HLS interface s_axilite port=exp_x 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 <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: #pragma HLS interface s_axilite port=exp_x The high-level-synthesis bug type of the code is: 'AMS' The right code snippet is: #pragma HLS interface ap_fifo port=exp_x
'AMS'
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
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: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
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: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
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: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
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: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x ...
The wrong part of the code is: for(int i=0; i<5; i++){ sineh = (e_to_x - e_to_neg_x) / 2.0f; cosh = (e_to_x + e_to_neg_x) / 2.0f; tanh = sineh / cosh; } The right code snippet is: // No inner loops to unroll
'ILNU'
Given the following buggy code, and the wrong part of the code, generate the right code snippet: The buggy code is: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); float e_to_x = exp...
The right code snippet is: // No inner loops to unroll
'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: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); float exp_neg_x = hls::exp(-x); fl...
The wrong part of the code is: for(int i=0; i<5; i++){ sineh = (e_to_x - e_to_neg_x) / 2.0f; cosh = (e_to_x + e_to_neg_x) / 2.0f; tanh = sineh / cosh; } 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: #include <hls_math.h> void Hyperbolic_Functions(float x, float &sineh, float &cosh, float &tanh) { float exp_x = hls::exp(x); f...
The wrong part of the code is: for(int i=0; i<5; i++){ sineh = (e_to_x - e_to_neg_x) / 2.0f; cosh = (e_to_x + e_to_neg_x) / 2.0f; tanh = sineh / cosh; } The high-level-synthesis bug type of the code is: 'ILNU' The right code snippet is: // No inner loops to unroll
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTER...
The wrong part of the code is: and1 = A1[10] & A2; The right code snippet is: and1 = A1 & A2;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTERFACE ...
The right code snippet is: and1 = A1 & A2;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragm...
The wrong part of the code is: and1 = A1[10] & A2; 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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_a...
The wrong part of the code is: and1 = A1[10] & A2; The high-level-synthesis bug type of the code is: 'OOB' The right code snippet is: and1 = A1 & A2;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTER...
The wrong part of the code is: bool and1, and2, or1, and3, not1, not2, and4; The right code snippet is: bool and1, and2, or1, and3, not1, not2;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTERFACE ...
The right code snippet is: bool and1, and2, or1, and3, not1, not2;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragm...
The wrong part of the code is: bool and1, and2, or1, and3, not1, not2, and4; 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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_a...
The wrong part of the code is: bool and1, and2, or1, and3, not1, not2, and4; The high-level-synthesis bug type of the code is: 'INIT' The right code snippet is: bool and1, and2, or1, and3, not1, not2;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTER...
The wrong part of the code is: not1 = A3 << 10; The right code snippet is: not1 = ~A3;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTERFACE ...
The right code snippet is: not1 = ~A3;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragm...
The wrong part of the code is: not1 = A3 << 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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_a...
The wrong part of the code is: not1 = A3 << 10; The high-level-synthesis bug type of the code is: 'SHFT' The right code snippet is: not1 = ~A3;
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTER...
The wrong part of the code is: for(int i=0; i>=0; i++){ // some code here } The right code snippet is: for(int i=0; i<10; i++){ // some code here }
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragma HLS INTERFACE ...
The right code snippet is: for(int i=0; i<10; i++){ // some code here }
'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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A2 bundle=CTRL_BUS #pragm...
The wrong part of the code is: for(int i=0; i>=0; i++){ // some code here } 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 s_axilite port=Y bundle=CTRL_BUS #pragma HLS INTERFACE s_axilite port=A1 bundle=CTRL_BUS #pragma HLS INTERFACE s_a...
The wrong part of the code is: for(int i=0; i>=0; i++){ // some code here } 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 here }
'INF'