Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • athena athena
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Jira
    • Jira
  • Merge requests 139
    • Merge requests 139
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Repository
  • Activity
  • Graph
  • Jobs
  • Commits
Collapse sidebar
  • atlasatlas
  • athenaathena
  • Merge requests
  • !40065

TrigInDetTriplet constructor: pass args by value

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Rafal Bielski requested to merge rbielski/athena:trig-triplet-construct-value into master Jan 28, 2021
  • Overview 14
  • Commits 1
  • Pipelines 1
  • Changes 1

Apply the "pass-by-value idiom" to TrigInDetTriplet constructor. This way the compiler doesn't have to create a temporary in this call:

output.emplace_back(*pSPI, *pS, *pSPO, Q);

here:
https://gitlab.cern.ch/atlas/athena/blob/master/Trigger/TrigTools/TrigInDetPattRecoTools/src/TrigTrackSeedGenerator.cxx#L1182
thus removing an unnecessary copy, which should result in a small performance gain (because the code is called many times).

Tested with full menu on 2k events. The statistics are not very conclusive but there seems to be some effect.
Before:

$ trigDumpTimers.py -p Triplets expert-monitoring.root 
expert-monitoring.root
TrigFastTrackFinder_bjet/TIME_Triplets 3.792 +/- 0.529
TrigFastTrackFinder_bphysics/TIME_Triplets 0
TrigFastTrackFinder_electron/TIME_Triplets 3.165 +/- 0.182
TrigFastTrackFinder_fullScan/TIME_Triplets 799.192 +/- 52.666
TrigFastTrackFinder_muon/TIME_Triplets 11.975 +/- 0.578
TrigFastTrackFinder_muonIso/TIME_Triplets 6.556 +/- 0.854
TrigFastTrackFinder_muonLRT/TIME_Triplets 0
TrigFastTrackFinder_tau/TIME_Triplets 7.37 +/- 1.457
TrigFastTrackFinder_tauCore/TIME_Triplets 4.447 +/- 0.315
TrigFastTrackFinder_tauIso/TIME_Triplets 0.043 +/- 0.019

After:

$ trigDumpTimers.py -p Triplets expert-monitoring.root 
expert-monitoring.root
TrigFastTrackFinder_bjet/TIME_Triplets 3.875 +/- 0.611
TrigFastTrackFinder_bphysics/TIME_Triplets 0
TrigFastTrackFinder_electron/TIME_Triplets 3.038 +/- 0.189
TrigFastTrackFinder_fullScan/TIME_Triplets 788.877 +/- 53.828
TrigFastTrackFinder_muon/TIME_Triplets 11.562 +/- 0.513
TrigFastTrackFinder_muonIso/TIME_Triplets 6.056 +/- 0.756
TrigFastTrackFinder_muonLRT/TIME_Triplets 0
TrigFastTrackFinder_tau/TIME_Triplets 7.239 +/- 1.807
TrigFastTrackFinder_tauCore/TIME_Triplets 4.32 +/- 0.323
TrigFastTrackFinder_tauIso/TIME_Triplets 0.009 +/- 0.009

Average total event processing time changed from 544 +/- 43 to 530 +/- 41.

Also apply "the rule of zero" i.e. remove the explicitly default-defined copy constructor.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: trig-triplet-construct-value