cpp: void print_array(int nx,\nDATA_TYPE POLYBENCH_1D(y,NX,nx))\n\n{\nint i;\n\nfor (i = 0; i < nx; i++) {\nfprintf (stderr, DATA_PRINTF_MODIFIER, y[i]);\nif (i % 20 == 0) fprintf (stderr, "\n");\n}\nfprintf (stderr, "\n");\n}
fortran: subroutine print_array(y, ny)\nimplicit none\n\nDATA_TYPE, dimension(ny) :: y\ninteger :: ny\ninteger :: i\ndo i = 1, ny\nwrite(0, DATA_PRINTF_MODIFIER) y(i)\nif (mod(i - 1, 20) == 0) then\nwrite(0, *)\nend if\nend do\nwrite(0, *)\nend subroutine