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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
GT.write(a >> 5 > b);
The right code snippet is:
GT.write(a > b); | 'SHFT' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
GT.write(a > b); | 'SHFT' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
GT.write(a >> 5 > b);
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
GT.write(a >> 5 > b);
The high-level-synthesis bug type of the code is: 'SHFT'
The right code snippet is:
GT.write(a > b); | 'SHFT' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
while(a == a) {
The right code snippet is:
while(1) { | 'INF' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
while(1) { | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
while(a == a) {
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
while(a == a) {
The high-level-synthesis bug type of the code is: 'INF'
The right code snippet is:
while(1) { | 'INF' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
int8_t a = A.read();
The right code snippet is:
ap_uint<4> a = A.read(); | 'USE' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
ap_uint<4> a = A.read(); | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
int8_t a = A.read();
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
int8_t a = A.read();
The high-level-synthesis bug type of the code is: 'USE'
The right code snippet is:
ap_uint<4> a = A.read(); | 'USE' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
for(int i=0; i<5; i++) {
The right code snippet is:
for(int i=0; i<4; i++) { | 'MLU' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
for(int i=0; i<4; 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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
for(int i=0; i<5; 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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
for(int i=0; i<5; i++) {
The high-level-synthesis bug type of the code is: 'MLU'
The right code snippet is:
for(int i=0; i<4; 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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
ap_uint<4> a = 0;
The right code snippet is:
ap_uint<4> a = A.read(); | 'ZERO' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
ap_uint<4> a = A.read(); | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
ap_uint<4> a = 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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
ap_uint<4> a = 0;
The high-level-synthesis bug type of the code is: 'ZERO'
The right code snippet is:
ap_uint<4> a = A.read(); | 'ZERO' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
ap_uint<4> a = B.read();
The right code snippet is:
ap_uint<4> a = A.read(); | 'BUF' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
ap_uint<4> a = A.read(); | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
ap_uint<4> a = B.read();
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
ap_uint<4> a = B.read();
The high-level-synthesis bug type of the code is: 'BUF'
The right code snippet is:
ap_uint<4> a = A.read(); | 'BUF' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A cyclic dim=1
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'APT' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'APT' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A 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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A cyclic dim=1
The high-level-synthesis bug type of the code is: 'APT'
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'APT' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A complete factor=3 dim=0
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'FND' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'FND' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A complete factor=3 dim=0
The high-level-synthesis bug type of the code is: 'FND' | 'FND' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A complete factor=3 dim=0
The high-level-synthesis bug type of the code is: 'FND'
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'FND' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=1
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'DID' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'DID' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=1
The high-level-synthesis bug type of the code is: 'DID' | 'DID' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=1
The high-level-synthesis bug type of the code is: 'DID'
The right code snippet is:
#pragma HLS ARRAY_PARTITION variable=A complete dim=0 | 'DID' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
#pragma HLS DATAFLOW flatten
The right code snippet is:
#pragma HLS DATAFLOW | 'DFP' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
#pragma HLS DATAFLOW flatten
The high-level-synthesis bug type of the code is: 'DFP' | 'DFP' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS DATAFLOW flatten
The high-level-synthesis bug type of the code is: 'DFP'
The right code snippet is:
#pragma HLS DATAFLOW | 'DFP' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE ap_fifo port=A
... |
The wrong part of the code is:
#pragma HLS INTERFACE ap_fifo port=A
The right code snippet is:
#pragma HLS INTERFACE axis port=A | 'IDAP' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE ap_fifo port=A
#pra... |
The right code snippet is:
#pragma HLS INTERFACE axis port=A | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE ap_fi... |
The wrong part of the code is:
#pragma HLS INTERFACE ap_fifo port=A
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS INTERFACE ap_fifo port=A
The high-level-synthesis bug type of the code is: 'IDAP'
The right code snippet is:
#pragma HLS INTERFACE axis port=A | 'IDAP' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
#pragma HLS INTERFACE m_axi port=A random
The right code snippet is:
#pragma HLS INTERFACE m_axi port=A | 'RAMB' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
#pragma HLS INTERFACE m_axi port=A | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
#pragma HLS INTERFACE m_axi port=A random
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS INTERFACE m_axi port=A random
The high-level-synthesis bug type of the code is: 'RAMB'
The right code snippet is:
#pragma HLS INTERFACE m_axi port=A | 'RAMB' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE bram port=A
#p... |
The wrong part of the code is:
#pragma HLS INTERFACE bram port=A
The right code snippet is:
#pragma HLS INTERFACE axis port=A | 'SMA' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE bram port=A
#pragma... |
The right code snippet is:
#pragma HLS INTERFACE axis port=A | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE bram ... |
The wrong part of the code is:
#pragma HLS INTERFACE bram port=A
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS INTERFACE bram port=A
The high-level-synthesis bug type of the code is: 'SMA'
The right code snippet is:
#pragma HLS INTERFACE axis port=A | 'SMA' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE ap_none port=A
... |
The wrong part of the code is:
#pragma HLS INTERFACE ap_none port=A
The right code snippet is:
#pragma HLS INTERFACE axis port=A | 'AMS' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE ap_none port=A
#pra... |
The right code snippet is:
#pragma HLS INTERFACE axis port=A | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE ap_no... |
The wrong part of the code is:
#pragma HLS INTERFACE ap_none port=A
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
#pragma HLS INTERFACE ap_none port=A
The high-level-synthesis bug type of the code is: 'AMS'
The right code snippet is:
#pragma HLS INTERFACE axis port=A | 'AMS' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#p... |
The wrong part of the code is:
for(int i=0; i<4; i+=2) {
The right code snippet is:
for(int i=0; i<4; i++) { | 'ILNU' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis port=A
#pragma... |
The right code snippet is:
for(int i=0; i<4; i++) { | '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:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> >
) {
#pragma HLS INTERFACE axis ... |
The wrong part of the code is:
for(int i=0; i<4; i+=2) {
The high-level-synthesis bug type of the code is: 'ILNU' | 'ILNU' |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
void magnitude_comparator(
hls::stream<ap_uint<4>> &A,
hls::stream<ap_uint<4>> &B,
hls::stream<bool> &EQ,
hls::stream<bool> ... |
The wrong part of the code is:
for(int i=0; i<4; i+=2) {
The high-level-synthesis bug type of the code is: 'ILNU'
The right code snippet is:
for(int i=0; i<4; i++) { | 'ILNU' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
#pragma HLS... |
The wrong part of the code is:
ap_uint<width> reg_data;
The right code snippet is:
static ap_uint<width> reg_data; | INIT |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
#include <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
#pragma HLS INTE... |
The right code snippet is:
static ap_uint<width> reg_data; | INIT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
#include <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
... |
The wrong part of the code is:
ap_uint<width> reg_data;
The high-level-synthesis bug type of the code is: INIT | INIT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_u... |
The wrong part of the code is:
ap_uint<width> reg_data;
The high-level-synthesis bug type of the code is: INIT
The right code snippet is:
static ap_uint<width> reg_data; | INIT |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
#pragma HLS... |
The wrong part of the code is:
lz_reg = (ap_uint<width>)(ap_int<width>)(reg_data != reg_data);
The right code snippet is:
lz_reg = (reg_data != reg_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_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
#pragma HLS INTE... |
The right code snippet is:
lz_reg = (reg_data != reg_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_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
... |
The wrong part of the code is:
lz_reg = (ap_uint<width>)(ap_int<width>)(reg_data != reg_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_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_u... |
The wrong part of the code is:
lz_reg = (ap_uint<width>)(ap_int<width>)(reg_data != reg_data);
The high-level-synthesis bug type of the code is: USE
The right code snippet is:
lz_reg = (reg_data != reg_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_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
#pragma HLS... |
The wrong part of the code is:
if (ld) {
reg_data = d;
lz_reg = 0;
} else {
for(int i=0; i<width; i++) {
lz_reg[i] = (reg_data[i] != reg_data[i]);
}
}
The right code snippet is:
if (ld) {
reg_data = d;
lz_reg = 0;
} else {
lz_reg = (reg_data != reg_data);
} | ILNU |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
#include <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
#pragma HLS INTE... |
The right code snippet is:
if (ld) {
reg_data = d;
lz_reg = 0;
} else {
lz_reg = (reg_data != reg_data);
} | 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 <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_uint<1>& lz, ap_uint<width>& z) {
... |
The wrong part of the code is:
if (ld) {
reg_data = d;
lz_reg = 0;
} else {
for(int i=0; i<width; i++) {
lz_reg[i] = (reg_data[i] != reg_data[i]);
}
}
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 <ap_int.h>
const int rscid = 1;
const int width = 8;
void stdreg_en(ap_uint<1> clk, ap_uint<1> ld, ap_uint<width> d, ap_u... |
The wrong part of the code is:
if (ld) {
reg_data = d;
lz_reg = 0;
} else {
for(int i=0; i<width; i++) {
lz_reg[i] = (reg_data[i] != reg_data[i]);
}
}
The high-level-synthesis bug type of the code is: ILNU
The right code snippet is:
if (ld) {
reg_data = d;
lz_reg = 0... | ILNU |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (i.range(31... |
The wrong part of the code is:
o = (i.range(31, 0), i.range(31, 31));
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'OOB' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (i.range(31, 0),... |
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | '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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = ... |
The wrong part of the code is:
o = (i.range(31, 0), i.range(31, 31));
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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma H... |
The wrong part of the code is:
o = (i.range(31, 0), i.range(31, 31));
The high-level-synthesis bug type of the code is: 'OOB'
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'OOB' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (i.range(30... |
The wrong part of the code is:
o = (i.range(30, -1), i.range(31, 31));
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'SHFT' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (i.range(30, -1)... |
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | '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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = ... |
The wrong part of the code is:
o = (i.range(30, -1), i.range(31, 31));
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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma H... |
The wrong part of the code is:
o = (i.range(30, -1), i.range(31, 31));
The high-level-synthesis bug type of the code is: 'SHFT'
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'SHFT' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
while(1) {
... |
The wrong part of the code is:
while(1) {
o = (i.range(30, 0), i.range(31, 31));
}
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'INF' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
while(1) {
o = (... |
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | '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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
whil... |
The wrong part of the code is:
while(1) {
o = (i.range(30, 0), i.range(31, 31));
}
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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma H... |
The wrong part of the code is:
while(1) {
o = (i.range(30, 0), i.range(31, 31));
}
The high-level-synthesis bug type of the code is: 'INF'
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'INF' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (ap_int<33>... |
The wrong part of the code is:
o = (ap_int<33>) (i.range(30, 0), i.range(31, 31));
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'USE' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (ap_int<33>) (i.... |
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | '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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = ... |
The wrong part of the code is:
o = (ap_int<33>) (i.range(30, 0), i.range(31, 31));
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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma H... |
The wrong part of the code is:
o = (ap_int<33>) (i.range(30, 0), i.range(31, 31));
The high-level-synthesis bug type of the code is: 'USE'
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'USE' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (i.range(63... |
The wrong part of the code is:
o = (i.range(63, 32), i.range(31, 0));
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'BUF' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = (i.range(63, 32)... |
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | '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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
o = ... |
The wrong part of the code is:
o = (i.range(63, 32), i.range(31, 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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma H... |
The wrong part of the code is:
o = (i.range(63, 32), i.range(31, 0));
The high-level-synthesis bug type of the code is: 'BUF'
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'BUF' |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
#pragma HLS arr... |
The wrong part of the code is:
#pragma HLS array_partition variable=o cyclic factor=3
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'APT' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
#pragma HLS array_pa... |
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | '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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma HLS INTERFACE ap_none port=o
#pra... |
The wrong part of the code is:
#pragma HLS array_partition variable=o cyclic factor=3
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:
```c++
#include <ap_int.h>
void shift_left_wrap(ap_uint<32> i, ap_uint<32> &o) {
#pragma HLS INTERFACE ap_none port=i
#pragma H... |
The wrong part of the code is:
#pragma HLS array_partition variable=o cyclic factor=3
The high-level-synthesis bug type of the code is: 'APT'
The right code snippet is:
o = (i.range(30, 0), i.range(31, 31)); | 'APT' |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.