From c6cb767c24247acd73234bc1d11413d08d4bc514 Mon Sep 17 00:00:00 2001
From: Tom Theuns <tom.theuns@durham.ac.uk>
Date: Mon, 7 Mar 2016 16:20:25 +0000
Subject: [PATCH] added task_verbose again

---
 src/runner.c | 14 ++++++++++++--
 src/task.h   |  2 +-
 2 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/src/runner.c b/src/runner.c
index 29d75f2735..74749f1227 100644
--- a/src/runner.c
+++ b/src/runner.c
@@ -67,8 +67,11 @@ const float runner_shift[13 * 3] = {
 /* Does the axis need flipping ? */
 const char runner_flip[27] = {1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0,
                               0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
-
-#define OUT  if(CELL_ID == MY_CELL) {message(" cell %d %d %f \n",CELL_ID, c->count, r->e->time);}
+#define MY_CELL 428428428
+#define DX     0.1
+#define NX     1000
+#define CELL_ID ( (int)(c->loc[0]/DX) * NX * NX + (int)(c->loc[1]/DX) * NX + (int)(c->loc[2]/DX))
+#define OUT  if(CELL_ID == MY_CELL) {message(" cell= %d gcount=%d time=%f \n",CELL_ID, c->gcount, r->e->time);}
 //#define OUT  message(" cell %d %d %f \n",CELL_ID, c->count, r->e->time);
 //#define OUT  if(CELL_ID == MY_CELL) message("\n cell %f %f %f %d %d %f\n",c->loc[0],c->loc[1],c->loc[2], CELL_ID, c->count, r->e->time);
 
@@ -778,6 +781,9 @@ void runner_dodrift(struct runner *r, struct cell *c, int timer) {
   float w;
 
   TIMER_TIC
+#ifdef TASK_VERBOSE
+	 OUT
+#endif
 
   /* No children? */
   if (!c->split) {
@@ -905,6 +911,10 @@ void runner_dokick(struct runner *r, struct cell *c, int timer) {
 
   TIMER_TIC
 
+#ifdef TASK_VERBOSE
+	 OUT
+#endif
+
   /* No children? */
   if (!c->split) {
 
diff --git a/src/task.h b/src/task.h
index 27b1b1fe9b..3e641ad2b0 100644
--- a/src/task.h
+++ b/src/task.h
@@ -25,7 +25,7 @@
 #include "cycle.h"
 
 /* Some constants. */
-//#define TASK_VERBOSE
+#define TASK_VERBOSE
 #define task_maxwait 3
 #define task_maxunlock 15
 
-- 
GitLab