From ab23cfc655580be48c1484ffa0a9c9e2eddcae17 Mon Sep 17 00:00:00 2001 From: "Steven R. Brandt" Date: Fri, 15 May 2020 09:46:49 -0500 Subject: [PATCH] Don't look at psync_mode --- Auxiliary/Cactus/SourceFiles/Kranc.hh | 48 +++------------------------ 1 file changed, 4 insertions(+), 44 deletions(-) diff --git a/Auxiliary/Cactus/SourceFiles/Kranc.hh b/Auxiliary/Cactus/SourceFiles/Kranc.hh index eab410d6..040ecc24 100644 --- a/Auxiliary/Cactus/SourceFiles/Kranc.hh +++ b/Auxiliary/Cactus/SourceFiles/Kranc.hh @@ -46,40 +46,6 @@ typedef void(*Kranc_Calculation)(cGH const * restrict cctkGH, // Boundary information - -static bool init = false; -static driver_bc_aliased; -static const int presync_mode; - -static void init_parameters() { - if(init) - return; - - init = false; - int type; - const CCTK_INT *tmp; - - const CCTK_STRING *tmp = (const CCTK_STRING *)CCTK_ParameterGet("presync_mode", "Cactus", &type); - if(tmp == 0 or *tmp == 0) - presync_mode = 0; - else if(CCTK_EQUALS(tmp, "off")) - presync_mode = 0; - else if(CCTK_EQUALS(tmp, "warn-only")) - presync_mode = 1; - else if(CCTK_EQUALS(tmp, "mixed-warn")) - presync_mode = 2; - else if(CCTK_EQUALS(tmp, "mixed-error")) - presync_mode = 3; - else if(CCTK_EQUALS(tmp, "presync-only")) - presync_mode = 4; - - if(CCTK_IsFunctionAliased("Driver_SelectVarForBC")) { - driver_bc_aliased = true; - } else { - driver_bc_aliased = false; - } -} - static CCTK_INT KrancBdy_SelectVarForBC( const CCTK_POINTER_TO_CONST cctkGH_, const CCTK_INT faces, @@ -88,14 +54,11 @@ static CCTK_INT KrancBdy_SelectVarForBC( const CCTK_STRING var_name, const CCTK_STRING bc_name) { - init_parameters(); - int ierr = 0; - if(presync_mode <= 3) - ierr = Boundary_SelectVarForBC(cctkGH_,faces,width,table_handle,var_name,bc_name); + ierr = Boundary_SelectVarForBC(cctkGH_,faces,width,table_handle,var_name,bc_name); - if(ierr == 0 && presync_mode >= 2) + if(ierr == 0) ierr = Driver_SelectVarForBC(cctkGH_,faces,width,table_handle,var_name,bc_name); return ierr; @@ -109,14 +72,11 @@ static CCTK_INT KrancBdy_SelectGroupForBC( const CCTK_STRING group_name, const CCTK_STRING bc_name) { - init_parameters(); - int ierr; - if(presync_mode <= 3) - ierr = Boundary_SelectGroupForBC(cctkGH_,faces,width,table_handle,group_name,bc_name); + ierr = Boundary_SelectGroupForBC(cctkGH_,faces,width,table_handle,group_name,bc_name); - if(ierr == 0 && presync_mode >= 2) + if(ierr == 0) ierr = Driver_SelectGroupForBC(cctkGH_,faces,width,table_handle,group_name,bc_name); return ierr;