From f21f8ed249030032f4b0a99c0fcd7e210ddb2e1b Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Sat, 10 Jul 2021 21:06:31 +0200 Subject: Add more documentation and clean up benchmarks --- benchmarks/polybench-syn/stencils/adi.c | 23 +++++++++-------------- 1 file changed, 9 insertions(+), 14 deletions(-) (limited to 'benchmarks/polybench-syn/stencils/adi.c') diff --git a/benchmarks/polybench-syn/stencils/adi.c b/benchmarks/polybench-syn/stencils/adi.c index ec2bf2a..2f4aca3 100644 --- a/benchmarks/polybench-syn/stencils/adi.c +++ b/benchmarks/polybench-syn/stencils/adi.c @@ -15,28 +15,23 @@ #include #endif -#define plus(i) i = i + ONE - static -void init_array (int n, - int u[ 20 + 0][20 + 0]) +void init_array (int n, int u[ 20 + 0][20 + 0]) { int i, j; for (i = 0; i < n; i++) for (j = 0; j < n; j++) - { - u[i][j] = divider((int)(i + n-j) ,n); - } + { + u[i][j] = divider((int)(i + n-j), n); + } } static -int print_array(int n, - int u[ 20 + 0][20 + 0]) - +int print_array(int n, int u[ 20 + 0][20 + 0]) { int i, j; int res = 0; @@ -53,10 +48,10 @@ int print_array(int n, } static void kernel_adi(int tsteps, int n, - int u[ 20 + 0][20 + 0], - int v[ 20 + 0][20 + 0], - int p[ 20 + 0][20 + 0], - int q[ 20 + 0][20 + 0]) + int u[ 20 + 0][20 + 0], + int v[ 20 + 0][20 + 0], + int p[ 20 + 0][20 + 0], + int q[ 20 + 0][20 + 0]) { int t, i, j; int B1, B2; -- cgit