aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Source/Evolve/WarpXEvolveEM.cpp1
-rw-r--r--Source/Parallelization/GuardCellManager.H3
-rw-r--r--Source/Parallelization/GuardCellManager.cpp4
3 files changed, 6 insertions, 2 deletions
diff --git a/Source/Evolve/WarpXEvolveEM.cpp b/Source/Evolve/WarpXEvolveEM.cpp
index 19031e006..38b959808 100644
--- a/Source/Evolve/WarpXEvolveEM.cpp
+++ b/Source/Evolve/WarpXEvolveEM.cpp
@@ -117,6 +117,7 @@ WarpX::EvolveEM (int numsteps)
if (num_mirrors>0){
applyMirrors(cur_time);
// E : guard cells are NOT up-to-date
+ // B : guard cells are NOT up-to-date
}
#ifdef WARPX_USE_PY
diff --git a/Source/Parallelization/GuardCellManager.H b/Source/Parallelization/GuardCellManager.H
index c6fdecaee..9f2bafa19 100644
--- a/Source/Parallelization/GuardCellManager.H
+++ b/Source/Parallelization/GuardCellManager.H
@@ -21,13 +21,14 @@ public:
const int maxwell_fdtd_solver_id,
const int max_level);
+ // Guard cells allocated for each multifab
amrex::IntVect ng_alloc_EB = amrex::IntVect::TheZeroVector();
amrex::IntVect ng_alloc_J = amrex::IntVect::TheZeroVector();
amrex::IntVect ng_alloc_Rho = amrex::IntVect::TheZeroVector();
amrex::IntVect ng_alloc_F = amrex::IntVect::TheZeroVector();
int ng_alloc_F_int = 0;
- // Guard cells to exchange data
+ // Guard cells exchanged for specific in the PIC loop
amrex::IntVect ng_FieldSolver = amrex::IntVect::TheZeroVector();
amrex::IntVect ng_FieldGather = amrex::IntVect::TheZeroVector();
amrex::IntVect ng_UpdateAux = amrex::IntVect::TheZeroVector();
diff --git a/Source/Parallelization/GuardCellManager.cpp b/Source/Parallelization/GuardCellManager.cpp
index cfe6e8470..28670fb91 100644
--- a/Source/Parallelization/GuardCellManager.cpp
+++ b/Source/Parallelization/GuardCellManager.cpp
@@ -119,6 +119,7 @@ guardCellManager::Init(
#else
ng_FieldSolver = IntVect(AMREX_D_DECL(1,1,1));
#endif
+ ng_FieldSolver = ng_FieldSolver.min(ng_alloc_EB);
// Compute number of cells required for Field Gather
int FGcell[4] = {0,1,1,2}; // Index is nox
@@ -136,7 +137,8 @@ guardCellManager::Init(
// separately.
ng_FieldGather = ng_FieldGather_noNCI + ng_NCIFilter;
- // Guard cells for auxiliary grid
+ // Guard cells for auxiliary grid.
+ // Not sure why there is a 2* here...
ng_UpdateAux = 2*ng_FieldGather_noNCI + ng_NCIFilter;
// Make sure we do not exchange more guard cells than allocated.