File tree Expand file tree Collapse file tree
Utilities/aliceHLTwrapper/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -33,17 +33,8 @@ using std::vector;
3333using std::unique_ptr;
3434using namespace ALICE ::HLT;
3535
36- // the chrono lib needs C++11
37- #if __cplusplus < 201103L
38- #warning statistics measurement for WrapperDevice disabled: need C++11 standard
39- #else
40- #define USE_CHRONO
41- #endif
42- #ifdef USE_CHRONO
43- #include < chrono>
4436using std::chrono::system_clock;
4537using TimeScale = std::chrono::milliseconds;
46- #endif // USE_CHRONO
4738
4839WrapperDevice::WrapperDevice (int argc, char ** argv, int verbosity)
4940 : mComponent(nullptr )
@@ -108,9 +99,7 @@ void WrapperDevice::Run()
10899 // / inherited from FairMQDevice
109100 int iResult=0 ;
110101
111- #ifdef USE_CHRONO
112102 static system_clock::time_point refTime = system_clock::now ();
113- #endif // USE_CHRONO
114103
115104 unique_ptr<FairMQPoller> poller (fTransportFactory ->CreatePoller (fChannels [" data-in" ]));
116105
@@ -162,7 +151,7 @@ void WrapperDevice::Run()
162151 // LOG(INFO) << "------ recieved complete Msg from " << numInputs << " input(s) after " << nReadCycles << " read cycles" ;
163152 // }
164153 nReadCycles=0 ;
165- # ifdef USE_CHRONO
154+
166155 auto duration = std::chrono::duration_cast<TimeScale>(std::chrono::system_clock::now () - refTime);
167156
168157 if (mLastSampleTime >=0 ) {
@@ -189,7 +178,6 @@ void WrapperDevice::Run()
189178 mMaxReadCycles =-1 ;
190179 mLastCalcTime =duration.count ();
191180 }
192- #endif // USE_CHRONO
193181
194182 if (!mSkipProcessing ) {
195183 // prepare input from messages
You can’t perform that action at this time.
0 commit comments