From b649023949f8a762d193833e192dbae8d53d105e Mon Sep 17 00:00:00 2001
From: Jan David Mol <mol@astron.nl>
Date: Thu, 7 Mar 2019 13:43:31 +0000
Subject: [PATCH] COB-5: Lower MPI polling as it seems to be good enough and
 stresses the system less.

---
 RTCP/Cobalt/InputProc/src/Transpose/MPIUtil.cc | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/RTCP/Cobalt/InputProc/src/Transpose/MPIUtil.cc b/RTCP/Cobalt/InputProc/src/Transpose/MPIUtil.cc
index fd13cf145dd..d63ccb350c2 100644
--- a/RTCP/Cobalt/InputProc/src/Transpose/MPIUtil.cc
+++ b/RTCP/Cobalt/InputProc/src/Transpose/MPIUtil.cc
@@ -446,11 +446,13 @@ namespace LOFAR {
       ScopedLock sl(mutex);
 
       while(!done) {
-        // next poll will be in 0.1 ms
+        // next poll will be in 0.5 ms
         //
         // NOTE: MPI is VERY sensitive to this, requiring
         //       often enough polling to keep transfers
         //       running smoothly.
+        //
+        // If the observations do not run at real time, try lowering the polling interval.
 
         if (requests.empty()) {
           // wait for request, with lock released
@@ -463,7 +465,7 @@ namespace LOFAR {
           // the lock and just wait with a timeout
           if (!requests.empty()) {
             struct timespec deadline = TimeSpec::now();
-            TimeSpec::inc(deadline, 0.0001);
+            TimeSpec::inc(deadline, 0.0005);
 
             newRequest.wait(mutex, deadline);
           }
-- 
GitLab