Skip to content

CaloTools; Protect against clang speculative evaluation.

Scott Snyder requested to merge ssnyder/athena:fpe.CaloTools-20221121 into master

In CaloNoiseCondAlg, clang may speculatively evaluate sqrt(lumi) even if due to m_noiseType it does not actually get used. However, in that case, it is possible that lumi is negative. This then leads to issues if one is looking at the results of FPEs.

Protect against this by ensuring that lumi is non-negative, even if the sqrt may not be evaluated. Needed to fix failure of FastCaloSim test in the clang build.

Merge request reports