cpp: void kernel_gemver(int n,\nDATA_TYPE alpha,\nDATA_TYPE beta,\nDATA_TYPE POLYBENCH_2D(A,N,N,n,n),\nDATA_TYPE POLYBENCH_1D(u1,N,n),\nDATA_TYPE POLYBENCH_1D(v1,N,n),\nDATA_TYPE POLYBENCH_1D(u2,N,n),\nDATA_TYPE POLYBENCH_1D(v2,N,n),\nDATA_TYPE POLYBENCH_1D(w,N,n),\nDATA_TYPE POLYBENCH_1D(x,N,n),\nDATA_TYPE POLYBENCH_1D(y,N,n),\nDATA_TYPE POLYBENCH_1D(z,N,n))\n{\nint i, j;\n\n#pragma scop\n\nfor (i = 0; i < _PB_N; i++)\nfor (j = 0; j < _PB_N; j++)\nA[i][j] = A[i][j] + u1[i] * v1[j] + u2[i] * v2[j];\n\nfor (i = 0; i < _PB_N; i++)\nfor (j = 0; j < _PB_N; j++)\nx[i] = x[i] + beta * A[j][i] * y[j];\n\nfor (i = 0; i < _PB_N; i++)\nx[i] = x[i] + z[i];\n\nfor (i = 0; i < _PB_N; i++)\nfor (j = 0; j < _PB_N; j++)\nw[i] = w[i] +  alpha * A[i][j] * x[j];\n\n#pragma endscop\n}
fortran: subroutine kernel_gemver(n, alpha, beta,  &\na, u1, v1, u2, v2, &\nw, x, y, z)\nimplicit none\n\nDATA_TYPE, dimension(n, n) :: a\nDATA_TYPE, dimension(n) :: u1\nDATA_TYPE, dimension(n) :: u2\nDATA_TYPE, dimension(n) :: v1\nDATA_TYPE, dimension(n) :: v2\nDATA_TYPE, dimension(n) :: w\nDATA_TYPE, dimension(n) :: x\nDATA_TYPE, dimension(n) :: y\nDATA_TYPE, dimension(n) :: z\nDATA_TYPE :: alpha, beta\ninteger :: n\ninteger :: i, j\n\n!$pragma scop\ndo i = 1, _PB_N\ndo j = 1, _PB_N\na(j, i) = a(j, i) + (u1(i) * v1(j)) + (u2(i) * v2(j))\nend do\nend do\ndo i = 1, _PB_N\ndo j = 1, _PB_N\nx(i) = x(i) + (beta * a(i, j) * y(j))\nend do\nend do\ndo i = 1, _PB_N\nx(i) = x(i) + z(i)\nend do\ndo i = 1, _PB_N\ndo j = 1, _PB_N\nw(i) = w(i) + (alpha * a(j, i) * x(j))\nend do\nend do\n!$pragma endscop\nend subroutine