From 10cb957bb41e588c9f0407ab0c99fd2c43706bbe Mon Sep 17 00:00:00 2001 From: Erik Schnetter Date: Tue, 19 Mar 2013 15:34:08 -0400 Subject: LoopControl: Simplify #if sequence --- Carpet/LoopControl/src/loopcontrol.cc | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'Carpet/LoopControl/src/loopcontrol.cc') diff --git a/Carpet/LoopControl/src/loopcontrol.cc b/Carpet/LoopControl/src/loopcontrol.cc index 2a9615607..c8ac8f99e 100644 --- a/Carpet/LoopControl/src/loopcontrol.cc +++ b/Carpet/LoopControl/src/loopcontrol.cc @@ -28,14 +28,14 @@ static inline int omp_get_thread_num() { return 0; } #endif -#ifdef HAVE_CAPABILITY_CYCLECLOCK + + +#if defined HAVE_CAPABILITY_CYCLECLOCK // We have a fast, accurate clock # include -#else - -# ifdef _OPENMP +#elif defined _OPENMP // We use the OpenMP clock typedef double ticks; @@ -43,7 +43,7 @@ static inline ticks getticks() { return omp_get_wtime(); } static inline double elapsed(ticks t1, ticks t0) { return t1-t0; } static inline double seconds_per_tick() { return 1.0; } -# else +#else // We use gettimeofday as fallback #include @@ -60,9 +60,10 @@ static inline double elapsed(ticks t1, ticks t0) } static inline double seconds_per_tick() { return 1.0e-6; } -# endif #endif + + using namespace std; -- cgit v1.2.3