From 6e0b30c8e62c310435cd937906dd4abc7d2b91ad Mon Sep 17 00:00:00 2001 From: schnetter Date: Tue, 10 Feb 2009 22:30:11 +0000 Subject: Split COPY macro into COPY_PRE, COPY_LOOP, and COPY_POST to allow adding OpenMP #pragma statements. git-svn-id: http://svn.cactuscode.org/arrangements/CactusNumerical/ReflectionSymmetry/trunk@25 082bdb00-0f4f-0410-b49e-b1835e5f2039 --- src/apply.c | 73 ++++++++++++++++++++++++++++++++++++++++++++----------------- 1 file changed, 53 insertions(+), 20 deletions(-) diff --git a/src/apply.c b/src/apply.c index d5223da..9375b56 100644 --- a/src/apply.c +++ b/src/apply.c @@ -18,7 +18,7 @@ CCTK_FILEVERSION(AEIDevelopment_ReflectionSymmetry_apply_c); -#define COPY(VARTYPE) \ +#define COPY_PRE(VARTYPE) \ static void \ copy_##VARTYPE (VARTYPE const * restrict const srcvar, \ VARTYPE * restrict const dstvar, \ @@ -29,8 +29,6 @@ CCTK_FILEVERSION(AEIDevelopment_ReflectionSymmetry_apply_c); int const idir, int const jdir, int const kdir, \ int const parity) \ { \ - int i, j, k; \ - \ int const iioff = ioff + (1 - idir) * imin; \ int const jjoff = joff + (1 - jdir) * jmin; \ int const kkoff = koff + (1 - kdir) * kmin; \ @@ -48,11 +46,12 @@ CCTK_FILEVERSION(AEIDevelopment_ReflectionSymmetry_apply_c); assert(kkmin>=0 && kkmax<=nk); \ assert(iimax>=-1 && iimin=-1 && jjmin=-1 && kkmin=-1 && kkmin