Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion PWGHF/TableProducer/trackIndexSkimCreator.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -4131,6 +4131,12 @@ struct HfTrackIndexSkimCreatorLfCascades {
continue;
}

// bachelor1 momentum is invariant across the inner (bachelor2) loop;
// pVector() is a dynamic column with no caching (it recomputes
// sin/cos on every call), so evaluate it once here instead of on
// every bachelor2 iteration.
const std::array<float, 3> pVecCharmBachelor1 = trackCharmBachelor1.pVector();
Comment thread
vkucera marked this conversation as resolved.
Outdated
Comment thread
ktf marked this conversation as resolved.
Outdated

// second loop over tracks
for (auto trackIdCharmBachelor2 = trackIdCharmBachelor1 + 1; trackIdCharmBachelor2 != groupedBachTrackIndices.end(); ++trackIdCharmBachelor2) {

Expand All @@ -4154,7 +4160,7 @@ struct HfTrackIndexSkimCreatorLfCascades {
continue;
}

if (!isPreselectedCandidateXic(pVecCasc, trackCharmBachelor1.pVector(), trackCharmBachelor2.pVector())) {
if (!isPreselectedCandidateXic(pVecCasc, pVecCharmBachelor1, trackCharmBachelor2.pVector())) {
continue;
}

Expand Down
Loading