From e12d4fce536f8bf53758c99075011f2760919199 Mon Sep 17 00:00:00 2001 From: schnetter Date: Sat, 3 Apr 2010 04:41:35 +0000 Subject: Correct OpenMP parallelisation of initialisation of boost and rotation git-svn-id: http://svn.einsteintoolkit.org/cactus/EinsteinInitialData/Exact/trunk@253 e296648e-0e4f-0410-bd07-d597d9acff87 --- src/boost.F77 | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/boost.F77 b/src/boost.F77 index dc26340..babe398 100644 --- a/src/boost.F77 +++ b/src/boost.F77 @@ -53,9 +53,6 @@ c output arguments $ guxx, guyy, guzz, guxy, guyz, guxz, $ psi -c intrinsic functions called - CCTK_REAL sqrt - c static local variables describing Lorentz transformation logical firstcall data firstcall /.true./ @@ -68,9 +65,8 @@ c static local variables describing Lorentz transformation CCTK_REAL R(0:3,0:3) save firstcall save gamma - save vv, nn + save vv save parallel, perp - save Cx_par, Cx_perp save partial_Mx_wrt_Cx save partial_Cx_wrt_Mx save R @@ -145,7 +141,8 @@ c c compute Lorentz transformation information on first call c if (firstcall) then - firstcall = .false. +c$omp critical + if (firstcall) then c boost velocity vv(1) = boost_vx @@ -295,6 +292,9 @@ c Mbetax(3) = Nbetax(1) c Mbetax(i) + R(i,j) Nbetax(j) [wrong] c Mbetax(i) + R(j,i) Nbetax(j) [correct] + firstcall = .false. + end if +c$omp end critical end if cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc -- cgit v1.2.3