6 #include <unordered_set> 29 if ( !sc.
isSuccess() ) warning() <<
"Base class could not be initialized" <<
endmsg;
32 info() <<
"Activating scheduler in a separate thread" <<
endmsg;
51 info() <<
"Joining preemptive scheduler's thread" <<
endmsg;
74 info() <<
"Start checking the queue of I/O-bound algorithm tasks.." <<
endmsg;
112 auto actionn = [&]() {
113 debug() <<
" .. launching I/O-bound algo-closure .. " <<
endmsg;
StatusCode initialize() override
StatusCode finalize() override
MsgStream & info() const
shortcut for the method msgStream(MSG::INFO)
bool m_isActive
Flag to track if the scheduler is active or not.
Header file for class GaudiAlgorithm.
std::thread m_thread
The thread in which the activate function runs.
virtual StatusCode execute()=0
#define DECLARE_COMPONENT(type)
General interface for a wrapper around Gaudi algorithm.
MsgStream & warning() const
shortcut for the method msgStream(MSG::WARNING)
This class is used for returning status codes from appropriate routines.
StatusCode deactivate()
Deactivate scheduler.
constexpr static const auto SUCCESS
MsgStream & debug() const
shortcut for the method msgStream(MSG::DEBUG)
void activate()
Activate scheduler.
StatusCode push(IAlgTask &task) override
Add an algorithm to local queue to run on accelerator.
StatusCode finalize() override
Finalise.
Please refer to the full documentation of the methods for more details.
tbb::concurrent_bounded_queue< action > m_actionsQueue
This is done since the copy of the lambda storage is too expensive.
MsgStream & endmsg(MsgStream &s)
MsgStream Modifier: endmsg. Calls the output method of the MsgStream.