[PPL-devel] [GIT] ppl/ppl(master): Detected by ECLAIR service inclmixd.

Roberto Bagnara bagnara at cs.unipr.it
Wed Aug 15 14:34:18 CEST 2012


Module: ppl/ppl
Branch: master
Commit: 2b67686580fa7ca3e4c75dac6d9b74791eedb521
URL:    http://www.cs.unipr.it/git/gitweb.cgi?p=ppl/ppl.git;a=commit;h=2b67686580fa7ca3e4c75dac6d9b74791eedb521

Author: Roberto Bagnara <bagnara at cs.unipr.it>
Date:   Wed Aug 15 14:24:30 2012 +0200

Detected by ECLAIR service inclmixd.

---

 src/globals.defs.hh |  110 ++++++++++++++++++++++++++++----------------------
 1 files changed, 62 insertions(+), 48 deletions(-)

diff --git a/src/globals.defs.hh b/src/globals.defs.hh
index 15340c2..c0a61ac 100644
--- a/src/globals.defs.hh
+++ b/src/globals.defs.hh
@@ -32,6 +32,68 @@ site: http://bugseng.com/products/ppl/ . */
 #include <exception>
 #include <gmpxx.h>
 
+#ifndef PPL_PROFILE_ADD_WEIGHT
+#define PPL_PROFILE_ADD_WEIGHT 0
+#endif
+
+#if defined(NDEBUG) && PPL_PROFILE_ADD_WEIGHT
+#include "Weight_Profiler.defs.hh"
+#endif
+
+#if defined(NDEBUG)
+
+#if PPL_PROFILE_ADD_WEIGHT
+
+#define WEIGHT_BEGIN() Weight_Profiler::begin()
+
+#define WEIGHT_ADD(delta)                                     \
+  do {                                                        \
+    static Weight_Profiler wp__(__FILE__, __LINE__, delta);   \
+    wp__.end();                                               \
+  } while (false)
+
+#define WEIGHT_ADD_MUL(delta, factor)                                   \
+  do {                                                                  \
+    static Weight_Profiler wp__(__FILE__, __LINE__, delta);             \
+    wp__.end(factor);                                                   \
+  } while (false)
+
+#else // !PPL_PROFILE_ADD_WEIGHT
+
+#define WEIGHT_BEGIN()                          \
+  do {                                          \
+  } while (false)
+
+#define WEIGHT_ADD(delta)                       \
+  do {                                          \
+    Weightwatch_Traits::weight += (delta);      \
+  } while (false)
+
+#define WEIGHT_ADD_MUL(delta, factor)                   \
+  do {                                                  \
+    Weightwatch_Traits::weight += (delta)*(factor);     \
+  } while (false)
+
+#endif // !PPL_PROFILE_ADD_WEIGHT
+
+#else // !defined(NDEBUG)
+
+#define WEIGHT_BEGIN()
+
+#define WEIGHT_ADD(delta)                       \
+  do {                                          \
+    if (!In_Assert::asserting())                \
+      Weightwatch_Traits::weight += delta;      \
+  } while (false)
+
+#define WEIGHT_ADD_MUL(delta, factor)                   \
+  do {                                                  \
+    if (!In_Assert::asserting())                        \
+      Weightwatch_Traits::weight += delta * factor;     \
+  } while (false)
+
+#endif // !defined(NDEBUG)
+
 
 namespace Parma_Polyhedra_Library {
 
@@ -497,54 +559,6 @@ least_significant_one_mask(dimension_type i);
 #define PPL_USE_SPARSE_MATRIX 1
 #endif
 
-#ifndef PPL_PROFILE_ADD_WEIGHT
-#define PPL_PROFILE_ADD_WEIGHT 0
-#endif
-
-#if defined(NDEBUG) && PPL_PROFILE_ADD_WEIGHT
-#include "Weight_Profiler.defs.hh"
-#endif
-
-#if defined(NDEBUG)
-#if PPL_PROFILE_ADD_WEIGHT
-#define WEIGHT_BEGIN() Weight_Profiler::begin()
-#define WEIGHT_ADD(delta)                                     \
-  do {                                                        \
-    static Weight_Profiler wp__(__FILE__, __LINE__, delta);   \
-    wp__.end();                                               \
-  } while (false)
-#define WEIGHT_ADD_MUL(delta, factor)                                   \
-  do {                                                                  \
-    static Weight_Profiler wp__(__FILE__, __LINE__, delta);             \
-    wp__.end(factor);                                                   \
-  } while (false)
-#else
-#define WEIGHT_BEGIN()                          \
-  do {                                          \
-  } while (false)
-#define WEIGHT_ADD(delta)                       \
-  do {                                          \
-    Weightwatch_Traits::weight += (delta);      \
-  } while (false)
-#define WEIGHT_ADD_MUL(delta, factor)                   \
-  do {                                                  \
-    Weightwatch_Traits::weight += (delta)*(factor);     \
-  } while (false)
-#endif
-#else
-#define WEIGHT_BEGIN()
-#define WEIGHT_ADD(delta)                       \
-  do {                                          \
-    if (!In_Assert::asserting())                       \
-      Weightwatch_Traits::weight += delta;      \
-  } while (false)
-#define WEIGHT_ADD_MUL(delta, factor)                   \
-  do {                                                  \
-    if (!In_Assert::asserting())                               \
-      Weightwatch_Traits::weight += delta * factor;     \
-  } while (false)
-#endif
-
 #include "globals.inlines.hh"
 
 #endif // !defined(PPL_globals_defs_hh)




More information about the PPL-devel mailing list