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:
```
#include "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = select ? vec[1] : 0;
mux_out[2] = select ? vec[2] : 0;
mux_out[3] = select ? vec[3] : 0;
The right code snippet is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = select ? vec[1] : 0;
mux_out[2... | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = select ? vec[1] : 0;
mux_out[2] = select ? vec[2] : 0; | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = select ? vec[1] : 0;
mux_out[2] = select ? vec[2] : 0;
mux_out[3] = select ? vec[3] : 0;
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = select ? vec[1] : 0;
mux_out[2] = select ? vec[2] : 0;
mux_out[3] = select ? vec[3] : 0;
The high-level-synthesis bug type of the code is: 'MLU'
The right code snippet is:
// Multiplexers
mux_out[0] = sele... | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out;
... |
The wrong part of the code is:
ap_uint<8> decoder_out;
The right code snippet is:
ap_uint<8> decoder_out = 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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out;
// ... |
The right code snippet is:
ap_uint<8> decoder_out = 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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
ap_uint<8> decoder_out;
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
ap_uint<8> decoder_out;
The high-level-synthesis bug type of the code is: 'ZERO'
The right code snippet is:
ap_uint<8> decoder_out = 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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
// Multiplexers
mux_out[3] = select ? vec[0] : 0;
mux_out[4] = select ? vec[1] : 0;
mux_out[5] = select ? vec[2] : 0;
The right code snippet is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = select ? vec[1] : 0;
mux_out[2] = select ? vec[2] : 0; | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = select ? vec[1] : 0;
mux_out[2] = select ? vec[2] : 0; | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
// Multiplexers
mux_out[3] = select ? vec[0] : 0;
mux_out[4] = select ? vec[1] : 0;
mux_out[5] = select ? vec[2] : 0;
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
// Multiplexers
mux_out[3] = select ? vec[0] : 0;
mux_out[4] = select ? vec[1] : 0;
mux_out[5] = select ? vec[2] : 0;
The high-level-synthesis bug type of the code is: 'BUF'
The right code snippet is:
// Multiplexers
mux_out[0] = select ? vec[0] : 0;
mux_out[1] = sele... | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out cyclic
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out cyclic
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out cyclic
The high-level-synthesis bug type of the code is: 'APT'
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out factor=3
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out factor=3
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out factor=3
The high-level-synthesis bug type of the code is: 'FND'
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out dim=1
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out 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:
```
#include "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS array_partition variable=mux_out dim=1
The high-level-synthesis bug type of the code is: 'DID'
The right code snippet is:
#pragma HLS array_partition variable=mux_out complete | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS dataflow region
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS dataflow region
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS dataflow region
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS interface ap_fifo port=outv
#pragma HLS interface ap_fifo port=o2
#pragma HLS interface ap_fifo port=o1
#pragma HLS interface ap_fifo port=o0
The right code snippet is:
#pragma HLS interface ap_none port=outv
#pragma HLS interface ap_none port=o2
#pragma HLS i... | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS interface ap_none port=outv
#pragma HLS interface ap_none port=o2
#pragma HLS interface ap_none port=o1
#pragma HLS interface ap_none port=o0 | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS interface ap_fifo port=outv
#pragma HLS interface ap_fifo port=o2
#pragma HLS interface ap_fifo port=o1
#pragma HLS interface ap_fifo port=o0
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS interface ap_fifo port=outv
#pragma HLS interface ap_fifo port=o2
#pragma HLS interface ap_fifo port=o1
#pragma HLS interface ap_fifo port=o0
The high-level-synthesis bug type of the code is: 'IDAP'
The right code snippet is:
#pragma HLS interface ap_none ... | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS interface m_axi port=image_data offset=slave bundle=wrong_bundle
The right code snippet is:
#pragma HLS interface m_axi port=image_data 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 "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS interface m_axi port=image_data 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 "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS interface m_axi port=image_data 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 "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS interface m_axi port=image_data 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=image_data 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 "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS interface ap_memory port=outv
The right code snippet is:
#pragma HLS interface ap_none port=outv | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS interface ap_none port=outv | '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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS interface ap_memory port=outv
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS interface ap_memory port=outv
The high-level-synthesis bug type of the code is: 'SMA'
The right code snippet is:
#pragma HLS interface ap_none port=outv | 'SMA' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
#include "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS interface axis port=outv
The right code snippet is:
#pragma HLS interface ap_none port=outv | 'AMS' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
#include "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS interface ap_none port=outv | 'AMS' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
#include "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
The wrong part of the code is:
#pragma HLS interface axis port=outv
The high-level-synthesis bug type of the code is: 'AMS' | 'AMS' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
The wrong part of the code is:
#pragma HLS interface axis port=outv
The high-level-synthesis bug type of the code is: 'AMS'
The right code snippet is:
#pragma HLS interface ap_none port=outv | '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 "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The wrong part of the code is:
#pragma HLS pipeline II=2
The right code snippet is:
#pragma HLS pipeline | 'MLP' |
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"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_out = 0;
... |
The right code snippet is:
#pragma HLS pipeline | '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 "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint<3> mux_out;
ap_uint<8> decoder_o... |
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 "ap_int.h"
void top_module(ap_uint<3> vec, bool select, ap_uint<3>& outv, bool& o2, bool& o1, bool& o0) {
ap_uint... |
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 | '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 "ap_cint.h"
#include "ap_utils.h"
void tcam(
ap_clk clk,
ap_uint<32> cmp_data_mask,
ap_uint<32> cmp_din,
ap_uint<32> data_mask,
ap_uint<32> din,
bool ... |
The wrong part of the code is:
ap_uint<1> en;
Bug_type:
'ILNU'
The right code snippet is:
ap_uint<1> en = 1; | 'INIT' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include "ap_cint.h"
#include "ap_utils.h"
void tcam(
ap_clk clk,
ap_uint<32> cmp_data_mask,
ap_uint<32> cmp_din,
ap_uint<32> data_mask,
ap_uint<32> din,
bool we,
... |
The right code snippet is:
ap_uint<1> en = 1; | '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_cint.h"
#include "ap_utils.h"
void tcam(
ap_clk clk,
ap_uint<32> cmp_data_mask,
ap_uint<32> cmp_din,
ap_uint<32> data_mask,
ap_uint<32> din... |
The wrong part of the code is:
ap_uint<1> en;
Bug_type:
'ILNU'
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_cint.h"
#include "ap_utils.h"
void tcam(
ap_clk clk,
ap_uint<32> cmp_data_mask,
ap_uint<32> cmp_din,
ap_ui... |
The wrong part of the code is:
ap_uint<1> en;
Bug_type:
'ILNU'
The high-level-synthesis bug type of the code is: 'INIT'
The right code snippet is:
ap_uint<1> en = 1; | '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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
ap_uint<5> num_items = wr_ptr + rd_ptr;
The right code snippet is:
ap_uint<5> num_items = wr_ptr - rd_ptr; | OOB |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
ap_uint<5> num_items = wr_ptr - rd_ptr; | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
ap_uint<5> num_items = wr_ptr + rd_ptr;
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
ap_uint<5> num_items = wr_ptr + rd_ptr;
The high-level-synthesis bug type of the code is: OOB
The right code snippet is:
ap_uint<5> num_items = wr_ptr - rd_ptr; | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
ap_uint<8> mem;
The right code snippet is:
static ap_uint<8> mem[depth]; | INIT |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
static ap_uint<8> mem[depth]; | INIT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
ap_uint<8> mem;
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
ap_uint<8> mem;
The high-level-synthesis bug type of the code is: INIT
The right code snippet is:
static ap_uint<8> mem[depth]; | INIT |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
ap_uint<5> next_wr_ptr = wr_ptr << 1;
The right code snippet is:
ap_uint<5> next_wr_ptr = wr_ptr + 1; | SHFT |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
ap_uint<5> next_wr_ptr = wr_ptr + 1; | SHFT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
ap_uint<5> next_wr_ptr = wr_ptr << 1;
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
ap_uint<5> next_wr_ptr = wr_ptr << 1;
The high-level-synthesis bug type of the code is: SHFT
The right code snippet is:
ap_uint<5> next_wr_ptr = wr_ptr + 1; | SHFT |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
while (rd_en && !empty) {
The right code snippet is:
if (rd_en && !empty) { | INF |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
if (rd_en && !empty) { | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
while (rd_en && !empty) {
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
while (rd_en && !empty) {
The high-level-synthesis bug type of the code is: INF
The right code snippet is:
if (rd_en && !empty) { | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
mem[wr_ptr] = (signed char)in_data.data;
The right code snippet is:
mem[wr_ptr] = in_data.data; | USE |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
mem[wr_ptr] = in_data.data; | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
mem[wr_ptr] = (signed char)in_data.data;
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
mem[wr_ptr] = (signed char)in_data.data;
The high-level-synthesis bug type of the code is: USE
The right code snippet is:
mem[wr_ptr] = in_data.data; | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
if (wr_en && !full) {
mem[wr_ptr] = in_data.data;
mem[wr_ptr + 1] = in_data.data;
wr_ptr = next_wr_ptr;
}
The right code snippet is:
if (wr_en && !full) {
mem[wr_ptr] = in_data.data;
wr_ptr = next_wr_ptr;
} | MLU |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
if (wr_en && !full) {
mem[wr_ptr] = in_data.data;
wr_ptr = next_wr_ptr;
} | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
if (wr_en && !full) {
mem[wr_ptr] = in_data.data;
mem[wr_ptr + 1] = in_data.data;
wr_ptr = next_wr_ptr;
}
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
if (wr_en && !full) {
mem[wr_ptr] = in_data.data;
mem[wr_ptr + 1] = in_data.data;
wr_ptr = next_wr_ptr;
}
The high-level-synthesis bug type of the code is: MLU
The right code snippet is:
if (wr_en && !full) {
mem[wr_ptr] = in_data.data;
wr_ptr = ne... | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
static ap_uint<8> mem[depth] = {0};
The right code snippet is:
static ap_uint<8> mem[depth]; | ZERO |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
static ap_uint<8> mem[depth]; | ZERO |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
static ap_uint<8> mem[depth] = {0};
The high-level-synthesis bug type of the code is: ZERO | ZERO |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
static ap_uint<8> mem[depth] = {0};
The high-level-synthesis bug type of the code is: ZERO
The right code snippet is:
static ap_uint<8> mem[depth]; | ZERO |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
out_data.data = mem[depth - rd_ptr];
The right code snippet is:
out_data.data = mem[rd_ptr]; | BUF |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
out_data.data = mem[rd_ptr]; | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
out_data.data = mem[depth - rd_ptr];
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
out_data.data = mem[depth - rd_ptr];
The high-level-synthesis bug type of the code is: BUF
The right code snippet is:
out_data.data = mem[rd_ptr]; | 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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem cyclic dim=1 factor=2
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | APT |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | APT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem cyclic dim=1 factor=2
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem cyclic dim=1 factor=2
The high-level-synthesis bug type of the code is: APT
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | APT |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem complete dim=2
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | FND |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | FND |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem complete dim=2
The high-level-synthesis bug type of the code is: FND | FND |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem complete dim=2
The high-level-synthesis bug type of the code is: FND
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | FND |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem complete dim=2
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | DID |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | DID |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem 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:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
#pragma HLS array_partition variable=mem complete dim=2
The high-level-synthesis bug type of the code is: DID
The right code snippet is:
#pragma HLS array_partition variable=mem complete dim=1 | DID |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
#include <ap_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragm... |
The wrong part of the code is:
#pragma HLS dataflow pipeline
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full) {
#pragma HLS... |
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en, bool rd_en, bool& empty, bool& full... |
The wrong part of the code is:
#pragma HLS dataflow pipeline
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_axi_sdata.h>
typedef ap_axis<8,1,1,1> AXI8;
const int depth = 16;
void fifo_hls(AXI8 in_data, AXI8& out_data, bool wr_en... |
The wrong part of the code is:
#pragma HLS dataflow pipeline
The high-level-synthesis bug type of the code is: DFP
The right code snippet is:
#pragma HLS dataflow | DFP |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.