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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS array_partition variable=Q dim=1
The right code snippet is:
N/A | 'DID' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/A | '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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
The wrong part of the code is:
#pragma HLS array_partition variable=Q 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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
The wrong part of the code is:
#pragma HLS array_partition variable=Q dim=1
The high-level-synthesis bug type of the code is: 'DID'
The right code snippet is:
N/A | '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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS dataflow
The right code snippet is:
N/A | 'DFP' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/A | '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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
The wrong part of the code is:
#pragma HLS dataflow
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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
The wrong part of the code is:
#pragma HLS dataflow
The high-level-synthesis bug type of the code is: 'DFP'
The right code snippet is:
N/A | '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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS interface ap_fifo port=Q
The right code snippet is:
N/A | 'IDAP' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
The wrong part of the code is:
#pragma HLS interface ap_fifo port=Q
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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
The wrong part of the code is:
#pragma HLS interface ap_fifo port=Q
The high-level-synthesis bug type of the code is: 'IDAP'
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS interface m_axi port=Q
The right code snippet is:
N/A | 'RAMB' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
The wrong part of the code is:
#pragma HLS interface m_axi port=Q
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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
The wrong part of the code is:
#pragma HLS interface m_axi port=Q
The high-level-synthesis bug type of the code is: 'RAMB'
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS interface axis port=Q
The right code snippet is:
N/A | 'SMA' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
The wrong part of the code is:
#pragma HLS interface axis port=Q
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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
The wrong part of the code is:
#pragma HLS interface axis port=Q
The high-level-synthesis bug type of the code is: 'SMA'
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS interface ap_vld port=Q
The right code snippet is:
N/A | 'AMS' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
The wrong part of the code is:
#pragma HLS interface ap_vld port=Q
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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
The wrong part of the code is:
#pragma HLS interface ap_vld port=Q
The high-level-synthesis bug type of the code is: 'AMS'
The right code snippet is:
N/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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS pipeline II=2
The right code snippet is:
N/A | 'MLP' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/A | '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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
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:
N/A | '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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INT... |
The wrong part of the code is:
#pragma HLS unroll factor=2
The right code snippet is:
N/A | 'ILNU' |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
void dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pragma HLS INTERFAC... |
The right code snippet is:
N/A | '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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERFACE ap_ctrl_none port=return
#pra... |
The wrong part of the code is:
#pragma HLS unroll factor=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 dff (
bool CLK,
bool D,
bool SCD,
bool SCE,
bool RESET_B,
bool &Q,
bool &Q_B
) {
#pragma HLS INTERF... |
The wrong part of the code is:
#pragma HLS unroll factor=2
The high-level-synthesis bug type of the code is: 'ILNU'
The right code snippet is:
N/A | '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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
ap_uint<2> A = 0;
The right code snippet is:
ap_uint<2> A; | 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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
ap_uint<2> A; | 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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
ap_uint<2> A = 0;
The high-level-synthesis bug type of the code is: INIT | INIT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
ap_uint<2> A = 0;
The high-level-synthesis bug type of the code is: INIT
The right code snippet is:
ap_uint<2> A; | 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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[2] ^ A[1];
... |
The wrong part of the code is:
xor_out = A[2] ^ A[1];
The right code snippet is:
xor_out = A[0] ^ A[1]; | OOB |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[2] ^ A[1];
//... |
The right code snippet is:
xor_out = A[0] ^ A[1]; | OOB |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[2]... |
The wrong part of the code is:
xor_out = A[2] ^ A[1];
The high-level-synthesis bug type of the code is: OOB | OOB |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
xor_out = A[2] ^ A[1];
The high-level-synthesis bug type of the code is: OOB
The right code snippet is:
xor_out = A[0] ^ A[1]; | OOB |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] << 3;
... |
The wrong part of the code is:
xor_out = A[0] << 3;
The right code snippet is:
xor_out = A[0] ^ A[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_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] << 3;
// O... |
The right code snippet is:
xor_out = A[0] ^ A[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_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
xor_out = A[0] << 3;
The high-level-synthesis bug type of the code is: SHFT | SHFT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
xor_out = A[0] << 3;
The high-level-synthesis bug type of the code is: SHFT
The right code snippet is:
xor_out = A[0] ^ A[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_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
while(1);
The right code snippet is:
Not applicable | INF |
Given the following buggy code, and the wrong part of the code, generate the right code snippet:
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | INF |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
while(1);
The high-level-synthesis bug type of the code is: INF | INF |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
while(1);
The high-level-synthesis bug type of the code is: INF
The right code snippet is:
Not applicable | INF |
Given the following buggy code, tell which part of the code is wrong, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
ap_int<2> A_signed = A;
The right code snippet is:
Not applicable | 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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
ap_int<2> A_signed = A;
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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
ap_int<2> A_signed = A;
The high-level-synthesis bug type of the code is: USE
The right code snippet is:
Not applicable | 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>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
for (int i = 0; i < 3; i++) {
xor_out = A[i] ^ A[i+1];
}
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
for (int i = 0; i < 3; i++) {
xor_out = A[i] ^ A[i+1];
}
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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
for (int i = 0; i < 3; i++) {
xor_out = A[i] ^ A[i+1];
}
The high-level-synthesis bug type of the code is: MLU
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
ap_uint<2> A = 0;
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
ap_uint<2> 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:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
ap_uint<2> A = 0;
The high-level-synthesis bug type of the code is: ZERO
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
ap_uint<2> B[2];
for (int i = 0; i < 2; i++) {
B[i] = A[i];
}
xor_out = B[0] ^ B[1];
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
ap_uint<2> B[2];
for (int i = 0; i < 2; i++) {
B[i] = A[i];
}
xor_out = B[0] ^ B[1];
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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
ap_uint<2> B[2];
for (int i = 0; i < 2; i++) {
B[i] = A[i];
}
xor_out = B[0] ^ B[1];
The high-level-synthesis bug type of the code is: BUF
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=3 dim=1
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=3 dim=1
The high-level-synthesis bug type of the code is: APT | APT |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=3 dim=1
The high-level-synthesis bug type of the code is: APT
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=4 dim=1
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=4 dim=1
The high-level-synthesis bug type of the code is: FND | FND |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=4 dim=1
The high-level-synthesis bug type of the code is: FND
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=2 dim=2
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=2 dim=2
The high-level-synthesis bug type of the code is: DID | DID |
Given the following buggy code, tell which part of the code is wrong, and tell the high-level-synthesis bug type, and tell the right code snippet
The buggy code is:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS array_partition variable=A cyclic factor=2 dim=2
The high-level-synthesis bug type of the code is: DID
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS dataflow
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS dataflow
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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS dataflow
The high-level-synthesis bug type of the code is: DFP
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS interface ap_none port=A
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS interface ap_none 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:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS interface ap_none port=A
The high-level-synthesis bug type of the code is: IDAP
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS interface m_axi port=A offset=slave depth=512
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS interface m_axi port=A offset=slave depth=512
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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS interface m_axi port=A offset=slave depth=512
The high-level-synthesis bug type of the code is: RAMB
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS interface axis port=A
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS interface axis 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:
```
#include <ap_int.h>
void sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS interface axis port=A
The high-level-synthesis bug type of the code is: SMA
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS interface s_axilite port=A bundle=CTRL_BUS
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
The wrong part of the code is:
#pragma HLS interface s_axilite port=A bundle=CTRL_BUS
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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
The wrong part of the code is:
#pragma HLS interface s_axilite port=A bundle=CTRL_BUS
The high-level-synthesis bug type of the code is: AMS
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
... |
The wrong part of the code is:
#pragma HLS pipeline II=2
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0] ^ A[1];
//... |
The right code snippet is:
Not applicable | 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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out;
// XOR gate
xor_out = A[0]... |
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 sky130_fd_sc_hd__parity_gen(ap_uint<2> A, ap_uint<1> &Y) {
// Internal signals
ap_uint<1> xor_out... |
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:
Not applicable | MLP |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.