summaryrefslogtreecommitdiff
path: root/src/Task.cc
diff options
context:
space:
mode:
authorNicolas Noble <pixel@nobis-crew.org>2013-08-01 17:15:45 -0700
committerNicolas Noble <pixel@nobis-crew.org>2013-08-01 17:15:45 -0700
commit95ea7b338aa5d48994ba96571811c25e9d44e41a (patch)
treeadf12663382ccd0359314cb5fe53953e37f83fb0 /src/Task.cc
parent48636e4f1b4fe378ac1fe20ca2c8c9a1f900e63f (diff)
Slightly more useful debugging messages in operationYield.
Diffstat (limited to 'src/Task.cc')
-rw-r--r--src/Task.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/Task.cc b/src/Task.cc
index 77217a5..788424b 100644
--- a/src/Task.cc
+++ b/src/Task.cc
@@ -290,7 +290,10 @@ void Balau::Task::operationYield(Events::BaseEvent * evt, enum OperationYieldTyp
"INTERRUPTIBLE",
"STACKLESS",
};
- Printer::elog(E_TASK, "operation back from yielding; yieldType = %s; okayToEAgain = %s", YieldTypeToString[yieldType], t->m_okayToEAgain ? "true" : "false");
+ if (doEAgain)
+ Printer::elog(E_TASK, "operation couldn't yield; yieldType = %s; okayToEAgain = %s", YieldTypeToString[yieldType], t->m_okayToEAgain ? "true" : "false");
+ else
+ Printer::elog(E_TASK, "operation back from yielding; yieldType = %s; okayToEAgain = %s", YieldTypeToString[yieldType], t->m_okayToEAgain ? "true" : "false");
gotSignal = evt ? evt->gotSignal() : true;
} while (((yieldType == SIMPLE) || !t->m_okayToEAgain) && !gotSignal);
@@ -298,7 +301,7 @@ void Balau::Task::operationYield(Events::BaseEvent * evt, enum OperationYieldTyp
return;
if ((yieldType != SIMPLE) && t->m_okayToEAgain && !gotSignal && doEAgain) {
- Printer::elog(E_TASK, "operation is throwing an exception.");
+ Printer::elog(E_TASK, "operation is throwing an EAgain exception with event %p", evt);
throw EAgain(evt);
}
}