aboutsummaryrefslogtreecommitdiffstats
path: root/benchmarks/polybench-syn/linear-algebra/kernels/bicg.c
diff options
context:
space:
mode:
authorNadesh Ramanathan <nadeshramanathan88@gmail.com>2020-11-11 19:47:42 +0000
committerNadesh Ramanathan <nadeshramanathan88@gmail.com>2020-11-11 19:47:42 +0000
commit95861dbef966e2cb612b303615681fc29c3acd3d (patch)
treee3bff372bdb4b769ec6fb54077e30bda406ef9ee /benchmarks/polybench-syn/linear-algebra/kernels/bicg.c
parent47bad8cabe00a40723ce04852d02e7527473f3c3 (diff)
downloadvericert-kvx-95861dbef966e2cb612b303615681fc29c3acd3d.tar.gz
vericert-kvx-95861dbef966e2cb612b303615681fc29c3acd3d.zip
polybench edits
Diffstat (limited to 'benchmarks/polybench-syn/linear-algebra/kernels/bicg.c')
-rw-r--r--benchmarks/polybench-syn/linear-algebra/kernels/bicg.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/benchmarks/polybench-syn/linear-algebra/kernels/bicg.c b/benchmarks/polybench-syn/linear-algebra/kernels/bicg.c
index 48b7658..5981924 100644
--- a/benchmarks/polybench-syn/linear-algebra/kernels/bicg.c
+++ b/benchmarks/polybench-syn/linear-algebra/kernels/bicg.c
@@ -10,6 +10,8 @@
/* bicg.c: this file is part of PolyBench/C */
+#include "../../include/misc.h"
+
#define plus(i) i = i + ONE
static
void init_array (int m, int n,
@@ -21,11 +23,11 @@ void init_array (int m, int n,
int ONE = 1;
for (i = 0; i < m; plus(i))
- p[i] = (int)(i % m) / m;
+ p[i] = divider(smodulo(i, m), m);
for (i = 0; i < n; plus(i)) {
- r[i] = (int)(i % n) / n;
+ r[i] = divider(smodulo(i, n), n);
for (j = 0; j < m; plus(j))
- A[i][j] = (int) (i*(j+ONE) % n)/n;
+ A[i][j] = divider(smodulo(i*(j+ONE), n), n);
}
}
@@ -65,7 +67,6 @@ void kernel_bicg(int m, int n,
int i, j;
int ONE = 1;
-#pragma scop
for (i = 0; i < m; plus(i))
s[i] = 0;
for (i = 0; i < n; plus(i))
@@ -77,7 +78,6 @@ void kernel_bicg(int m, int n,
q[i] = q[i] + A[i][j] * p[j];
}
}
-#pragma endscop
}