Skip to content

Commit

Permalink
remove more FillBoundary calls
Browse files Browse the repository at this point in the history
  • Loading branch information
asalmgren committed Dec 14, 2023
1 parent a779c97 commit e29688b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 16 deletions.
16 changes: 0 additions & 16 deletions Source/TimeIntegration/ROMSX_advance_2d.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -256,9 +256,6 @@ ROMSX::advance_2d (int lev,
DVom(i,j,0)=vbar(i,j,0,krhs)*cff1;
});
}
mf_DUon.FillBoundary(geom[lev].periodicity());
mf_DVom.FillBoundary(geom[lev].periodicity());


for ( MFIter mfi(*mf_rhoS, TilingIfNotGPU()); mfi.isValid(); ++mfi )
{
Expand Down Expand Up @@ -866,17 +863,4 @@ ROMSX::advance_2d (int lev,
});
}
}
mf_DU_avg1->FillBoundary(geom[lev].periodicity());
mf_DU_avg2->FillBoundary(geom[lev].periodicity());
mf_DV_avg1->FillBoundary(geom[lev].periodicity());
mf_DV_avg2->FillBoundary(geom[lev].periodicity());
mf_ru->FillBoundary(geom[lev].periodicity());
mf_rv->FillBoundary(geom[lev].periodicity());
mf_rubar->FillBoundary(geom[lev].periodicity());
mf_rvbar->FillBoundary(geom[lev].periodicity());
mf_rzeta->FillBoundary(geom[lev].periodicity());
mf_ubar->FillBoundary(geom[lev].periodicity());
mf_vbar->FillBoundary(geom[lev].periodicity());
mf_zeta->FillBoundary(geom[lev].periodicity());

}
10 changes: 10 additions & 0 deletions Source/TimeIntegration/ROMSX_advance_2d_onestep.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ void ROMSX::advance_2d_onestep (int lev, Real /*dt_lev*/, Real dtfast_lev, int m
{
bool first_2d_step=(my_iif==0);

// These are needed to pass ctests
Real dummy_time = 0.0;
FillPatch(lev, dummy_time, *vec_ubar[lev], GetVecOfPtrs(vec_ubar));
FillPatch(lev, dummy_time, *vec_vbar[lev], GetVecOfPtrs(vec_vbar));

//Predictor
bool predictor_2d_step=true;
int next_indx1 = 0;
Expand All @@ -25,6 +30,11 @@ void ROMSX::advance_2d_onestep (int lev, Real /*dt_lev*/, Real dtfast_lev, int m
//Corrector. Skip it on last fast step
predictor_2d_step=false;
if (my_iif < nfast_counter - 1) {

// These are needed to pass ctests
FillPatch(lev, dummy_time, *vec_ubar[lev], GetVecOfPtrs(vec_ubar));
FillPatch(lev, dummy_time, *vec_vbar[lev], GetVecOfPtrs(vec_vbar));

advance_2d(lev, *xvel_new[lev], *yvel_new[lev],
vec_rhoS[lev].get(), vec_rhoA[lev].get(),
vec_ru[lev].get(), vec_rv[lev].get(),
Expand Down

0 comments on commit e29688b

Please sign in to comment.