Skip to content

Bootstrap.cpp: Relinquish python's GIL before calling executeRun to allow python algs in MT mode

Walter Lampl requested to merge wlampl/Gaudi:relinquishGILBeforeRun into master

I assume this needs a bit of discussion in a ATLAS Core SW meeting and/or a Gaudi meeting.

Background: ATLAS Data Quality relies on post-processing of histograms implement as python algorithm. When running as online monitoring at P1, these python post-processing is invoked as algorithm in the event loop to present the shifter in the control room real-time histograms. Running this job in MT-mode creates a deadlock between the python-code doing the configuration and invoking the run-method of the c++-application and python code executed as algorithm in a different thread. The call chain is: python -> C++ spawning threads -> python.

The changeset here solves this problem by invoking the macro Py_BEGIN_ALLOW_THREADS just before calling IEventProcessor::executeRun.

Tagging @ssnyder, @ponyisi and @pavol

Merge request reports