Skip to content

Commit

Permalink
Use CCTK_ macros instead of LC_ macros for looping
Browse files Browse the repository at this point in the history
  • Loading branch information
eschnett committed Jan 17, 2013
1 parent ef0e9bb commit d1db387
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Tools/CodeGen/CodeGenCactus.m
Expand Up @@ -385,19 +385,19 @@
CommentedBlock[
"Loop over the grid points",
{"#pragma omp parallel\n",
If[vectorise, "LC_LOOP3VEC", "CCTK_LOOP3"],
If[vectorise, "CCTK_LOOP3STR", "CCTK_LOOP3"],
"(", functionName, ",\n",
" i,j,k, imin[0],imin[1],imin[2], imax[0],imax[1],imax[2],\n",
" cctk_ash[0],cctk_ash[1],cctk_ash[2]",
If[vectorise, {",\n", " CCTK_REAL_VEC_SIZE"}, ""],
If[vectorise, {",\n", " imin,imax, CCTK_REAL_VEC_SIZE"}, ""],
")\n",
"{\n",
IndentBlock[
{(* DeclareVariable["index", "// int"], *)
(* DeclareAssignVariable["int", "index", "CCTK_GFINDEX3D(cctkGH,i,j,k)"], *)
DeclareAssignVariable["ptrdiff_t", "index", "di*i + dj*j + dk*k"],
block}], "}\n",
If[vectorise, "LC_ENDLOOP3VEC", "CCTK_ENDLOOP3"] <> "(", functionName, ");\n"}],
If[vectorise, "CCTK_ENDLOOP3STR", "CCTK_ENDLOOP3"] <> "(", functionName, ");\n"}],
(* else *)
""]];

Expand Down

0 comments on commit d1db387

Please sign in to comment.