fork()-ing a multi-thread program typically ends up badly. In ROOT, TBB spawns threads when RTaskArena is constructed, and Cocoa spawns threads, on Mac, when graphics are activated.
We would like to employ a similar mechanism to what is used to loop over threads to print their stacktraces on a crash in order to detect whether TTreeProcessorMP::Process is called from a multi-thread program, and warn users if so.
fork()-ing a multi-thread program typically ends up badly. In ROOT, TBB spawns threads when RTaskArena is constructed, and Cocoa spawns threads, on Mac, when graphics are activated.We would like to employ a similar mechanism to what is used to loop over threads to print their stacktraces on a crash in order to detect whether
TTreeProcessorMP::Processis called from a multi-thread program, and warn users if so.