Hello!
Are the TH histogram classes thread safe? I’m thinking about a threaded program like this (just using root as libraries for c++):
#pragma omp parallel for firstprivate (localdata)
for(int i=0; i<entries; i++){ // entryloop start
#pragma omp critical
{
chain->GetEntry(i);
localdata.setData(*data); // makes a copy of the data
}
histogram->Fill(localdata.GetCharge());
} // entryloop end
My main concern is that I might run into some hard to debug race conditions…
Thanks in advance!