diff options
author | Nadesh Ramanathan <nadeshramanathan88@gmail.com> | 2020-11-15 11:44:21 +0000 |
---|---|---|
committer | Nadesh Ramanathan <nadeshramanathan88@gmail.com> | 2020-11-15 11:44:21 +0000 |
commit | aba1066919919bf068b723fca3741be6f3a1de97 (patch) | |
tree | 84fe16aa550b7cff31f16ea824bcac552773de02 /benchmarks/polybench-syn/linear-algebra/solvers/trisolv.c | |
parent | 95861dbef966e2cb612b303615681fc29c3acd3d (diff) | |
download | vericert-aba1066919919bf068b723fca3741be6f3a1de97.tar.gz vericert-aba1066919919bf068b723fca3741be6f3a1de97.zip |
some fixes
Diffstat (limited to 'benchmarks/polybench-syn/linear-algebra/solvers/trisolv.c')
-rw-r--r-- | benchmarks/polybench-syn/linear-algebra/solvers/trisolv.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/benchmarks/polybench-syn/linear-algebra/solvers/trisolv.c b/benchmarks/polybench-syn/linear-algebra/solvers/trisolv.c index 8e76231..2f636df 100644 --- a/benchmarks/polybench-syn/linear-algebra/solvers/trisolv.c +++ b/benchmarks/polybench-syn/linear-algebra/solvers/trisolv.c @@ -11,6 +11,11 @@ #include "../../include/misc.h" + +#ifndef SYNTHESIS +#include <stdio.h> +#endif + #define plus(i) i = i + ONE static void init_array(int n, @@ -23,7 +28,7 @@ void init_array(int n, for (i = 0; i < n; plus(i)) { - x[i] = - 999; + x[i] = -999; b[i] = i ; for (j = 0; j <= i; plus(j)) L[i][j] = (int) divider((i+n-j+ONE)*(ONE+ONE), n); @@ -42,8 +47,12 @@ int check_array(int n, int res = 0; int ONE = 1; for (i = 0; i < n; plus(i)) { - res += x[i]; + res ^= x[i]; } + +#ifndef SYNTHESIS + printf("finished: %u\n", res); +#endif return res; } |