I am trying to set up multi-threaded fitting and this post is somewhat a follow up to topic:
[url]Is TH1::Fit thread-safe?
where others have tried to setup parallel fitting with ROOT.
Attached is a “simple” example how I have set up the multi-threaded fitting using the ROOT::Fit::Fitter class (instead of TH1::Fit). The ROOT script works fine as long as I am only using one thread. It works also fine if I use multiple threads and do not actually call the “Fit” function. But if I use multiple threads and call “Fit” then is crashes usually somewhere in the fit classes - not always at the same point though.
So my questions are:
Do I have to do something special/magic to get it to work. … or …
Is ROOT simply not capable of multi-threaded fitting?
Thanks a lot for any help,
ParallelFitting.C (7.38 KB)