Skip to content
Snippets Groups Projects

DataObjID: on-demand lookup of className

Merged Frank Winklmeier requested to merge fwinkl/Gaudi:dataobjid into master

Retrieving the class name to a CLID requires querying the ClassIDSvc, which (at least in the ATLAS implementation) requires taking a lock during the lookup and in general might be a costly operation. Instead of doing this in the construction of DataObjID only lookup the class name when needed and then cache the result. For many use-cases, the class name will never be retrieved.

Also cleanup the needlessly complicated code of one-time retrieval of ClassIDSvc by using a simple static and add a unit test.

This speeds up construction of DataObjID (for the ATLAS use-case) by about 10% for a single threaded-job. But seeing a factor of 15-20 speedup for synthetic heavily thread contented job using 8 threads (see also ATEAM-1054).

cc @ssnyder @leggett @tadej @akraszna

Edited by Frank Winklmeier

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading