aboutsummaryrefslogtreecommitdiff
path: root/Carpet/Carpet/src/Evolve.cc
diff options
context:
space:
mode:
authorErik Schnetter <schnetter@gmail.com>2013-04-02 17:40:41 -0400
committerErik Schnetter <schnetter@gmail.com>2013-04-02 17:40:41 -0400
commitc0c03fece68597fddfef57948334c5c99154f244 (patch)
treee3d32c456ff55c6eaafa684e1e2438514d46706b /Carpet/Carpet/src/Evolve.cc
parentafd93dce86328a3489608b729894bb34add6cb90 (diff)
Requirements: New thorn
Move requirement handling code out of Carpet and into a new thorn.
Diffstat (limited to 'Carpet/Carpet/src/Evolve.cc')
-rw-r--r--Carpet/Carpet/src/Evolve.cc10
1 files changed, 8 insertions, 2 deletions
diff --git a/Carpet/Carpet/src/Evolve.cc b/Carpet/Carpet/src/Evolve.cc
index 2d1541f72..8864ee9ee 100644
--- a/Carpet/Carpet/src/Evolve.cc
+++ b/Carpet/Carpet/src/Evolve.cc
@@ -13,6 +13,8 @@
#include <cctk_Parameters.h>
#include <cctk_Termination.h>
+#include <Requirements.hh>
+
#include <util_String.h>
#include <dist.hh>
@@ -23,8 +25,6 @@
#include <TimerSet.hh>
#include <TimerNode.hh>
-#include "Requirements.hh"
-
namespace Carpet {
@@ -295,7 +295,9 @@ namespace Carpet {
assert (not did_remove_level or did_regrid);
if (did_regrid) {
+#ifdef REQUIREMENTS_HH
Requirements::Regrid(reflevels);
+#endif
bool did_any_recompose = false;
BEGIN_META_MODE (cctkGH) {
@@ -308,10 +310,12 @@ namespace Carpet {
bool const did_recompose = Recompose (cctkGH, rl, true);
did_any_recompose = did_any_recompose or did_recompose;
+#ifdef REQUIREMENTS_HH
Requirements::Recompose(rl,
not did_recompose ?
Requirements::valid::everywhere :
Requirements::valid::interior);
+#endif
// Carpet assumes that a regridding operation always changes
// "level N and all finer levels" so we should call
@@ -372,7 +376,9 @@ namespace Carpet {
if (have_done_anything) assert (have_done_late_global_mode);
} END_META_MODE;
+#ifdef REQUIREMENTS_HH
Requirements::RegridFree();
+#endif
} // if did_regrid
RegridFree (cctkGH, true);