Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,21 @@

void add_kernel(int tmp1[128], int tmp2[128], int tmp3[128]) {

int buff[127];
for (int i = 0; i < 128; i++) {
tmp3[i] = tmp1[i] + tmp2[i];
}
}

void double_pass(int b[128], int tmp2[128], int tmp1[128], int tmp4[128]) {

int buff[127];
for (int i = 0; i < 128; i++) {
tmp2[i] = b[i];
tmp4[i] = tmp1[i];
}
}

void pass(int a[128], int tmp1[128]) {

for (int i = 0; i < 128; i++) {
tmp1[i] = a[i];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,21 @@

void add_kernel(int tmp1[128], int tmp2[128], int tmp3[128]) {

int buff[127];
for (int i = 0; i < 128; i++) {
tmp3[i] = tmp1[i] + tmp2[i];
}
}

void Double_pass(int tmp2[128], int tmp1[128], int tmp4[128], int tmp5[128]) {

int buff[127];
for (int i = 0; i < 128; i++) {
tmp4[i] = tmp1[i];
tmp5[i] = tmp2[i];
}
}

void pass(int a[128], int b[128], int tmp1[128], int tmp2[128]) {

for (int i = 0; i < 128; i++) {
tmp1[i] = a[i];
tmp2[i] = b[i];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ int main() {

for (int j = 0; j < 512; j++) {
if (tmp[j] != 2 * j) {
std::cout << "value of i is" << j << "value of a[j] is" << a[j]
<< "value of out b[j] is " << b[j]
std::cout << "value of j is" << j << "value of a[j] is" << a[j]
<< "value of b[j] is " << b[j]
<< "value of tmp[j] is " << tmp[j] << std::endl;
return 1;
break;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,28 +16,22 @@
*/

void bypass(int tmp1[128], int tmp2[128], int tmp3[128]) {
// static int j;

int buff[127];
for (int i = 0; i < 128; i++) {
tmp3[i] = tmp1[i] + tmp2[i];
}
}

void pass(int tmp2[128], int tmp4[128]) {
// static int j;

int buff[127];
for (int i = 0; i < 128; i++) {

tmp4[i] = tmp2[i];
}
}

void double_pass(int a[128], int b[128], int tmp1[128], int tmp2[128]) {
static int j;

for (int i = 0; i < 128; i++) {
j++;
tmp1[i] = a[i];
tmp2[i] = b[i];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,16 @@ void bypass(int tmp1[128], int tmp2[128], int tmp3[128]) {
}

void pass(int tmp2[128], int tmp4[128], int tmp1[128], int tmp5[128]) {
// static int j;

int buff[127];
for (int i = 0; i < 128; i++) {

tmp4[i] = tmp2[i];
tmp5[i] = tmp1[i];
}
}

void double_pass(int a[128], int b[128], int tmp1[128], int tmp2[128]) {
static int j;

for (int i = 0; i < 128; i++) {
j++;
tmp1[i] = a[i];
tmp2[i] = b[i];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ int main() {

for (int j = 0; j < 512; j++) {
if (tmp[j] != a[j] + b[j]) {
std::cout << "value of i is" << j << "value of a[j] is" << a[j]
<< "value of out b[j] is " << b[j]
std::cout << "value of j is" << j << "value of a[j] is" << a[j]
<< "value of b[j] is " << b[j]
<< "value of tmp[j] is " << tmp[j] << std::endl;
return 1;
break;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,15 @@
*/

void pass(int tmp1[128], int b[128]) {
int buff[127];

for (int i = 0; i < 128; i++) {
b[i] = tmp1[i];
}
}

void split(int a[128], int tmp1[128], int tmp2[128]) {
static int j;

for (int i = 0; i < 128; i++) {
j++;
tmp1[i] = a[i];
tmp2[i] = a[i];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,16 @@
*/

void pass(int tmp3[128], int tmp2[128], int tmp1[128], int b[128]) {

for (int i = 0; i < 128; i++) {
b[i] = tmp1[i];
tmp2[i] = tmp3[i];
}
}

void split(int a[128], int tmp1[128], int tmp2[128]) {
static int j;

for (int i = 0; i < 128; i++) {
j++;
tmp1[i] = a[i];
tmp2[i] = a[i];
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ int main() {

for (int j = 0; j < 512; j++) {
if (b[j] != (a[j]) || tmp[j] != a[j]) {
std::cout << "value of i is" << j << "value of a[j] is" << a[j]
<< "value of out b[j] is " << b[j]
std::cout << "value of j is" << j << "value of a[j] is" << a[j]
<< "value of b[j] is " << b[j]
<< "value of tmp[j] is " << tmp[j] << std::endl;
return 1;
break;
Expand Down