From a6a3f799e77a874849fac500db4921da23c030d0 Mon Sep 17 00:00:00 2001 From: Johann Dreo Date: Tue, 10 Sep 2024 10:57:50 +0200 Subject: [PATCH] fix(eoParallel): declutch _t_start under _OPENMP --- eo/src/utils/eoParallel.cpp | 6 ++++-- eo/src/utils/eoParallel.h | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/eo/src/utils/eoParallel.cpp b/eo/src/utils/eoParallel.cpp index cae5e8c41..41704c54b 100644 --- a/eo/src/utils/eoParallel.cpp +++ b/eo/src/utils/eoParallel.cpp @@ -39,8 +39,10 @@ eoParallel::eoParallel() : _nthreads( 0, "parallelize-nthreads", "Define the number of threads you want to use, nthreads = 0 means you want to use all threads available", '\0' ), _enableResults( false, "parallelize-enable-results", "Enable the generation of results", '\0' ), _doMeasure( false, "parallelize-do-measure", "Do some measures during execution", '\0' ), - _packetSize( 1U, "parallelize-packet-size", "Number of elements which should be sent in a single message during a parallel evaluation based on message passing.", '\0'), - _t_start(0) + _packetSize( 1U, "parallelize-packet-size", "Number of elements which should be sent in a single message during a parallel evaluation based on message passing.", '\0') +#ifdef _OPENMP + , _t_start(0) +#endif { } diff --git a/eo/src/utils/eoParallel.h b/eo/src/utils/eoParallel.h index 6608706dc..929d955d6 100644 --- a/eo/src/utils/eoParallel.h +++ b/eo/src/utils/eoParallel.h @@ -71,7 +71,9 @@ private: eoValueParam _enableResults; eoValueParam _doMeasure; eoValueParam _packetSize; +#ifdef _OPENMP double _t_start; +#endif }; void make_parallel(eoParser&);