diff options
author | Yann Herklotz <git@yannherklotz.com> | 2020-11-14 16:23:00 +0000 |
---|---|---|
committer | Yann Herklotz <git@yannherklotz.com> | 2020-11-14 16:23:00 +0000 |
commit | 4201a38997543ceedad52f77b992dd8eb4a2ee5e (patch) | |
tree | 16b4adb28028e21f3ae9d46539167ece72c1c4a8 /benchmarks/polybench-syn/linear-algebra/kernels/bicg.c | |
parent | 43773b8d4a69dfd30759db2a5026a4f44cdac4cb (diff) | |
parent | 95861dbef966e2cb612b303615681fc29c3acd3d (diff) | |
download | vericert-kvx-4201a38997543ceedad52f77b992dd8eb4a2ee5e.tar.gz vericert-kvx-4201a38997543ceedad52f77b992dd8eb4a2ee5e.zip |
Merge branch 'dev-experiments'
Diffstat (limited to 'benchmarks/polybench-syn/linear-algebra/kernels/bicg.c')
-rw-r--r-- | benchmarks/polybench-syn/linear-algebra/kernels/bicg.c | 10 |
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 } |