-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
GeometrySplit functor isn't threadsafe (#1607)
### Briefly, what does this PR introduce? Fixes issues with the initialization of the GeometrySplit functor across threads. Currently only the std::once_flag is a shared pointer and none of the other variables which are being initialized. This meant that when copied to other threads the is_init flag was set but the decoder and geometry divisions had not been so the loop over the detector ids was always empty. This resulted in an apparent variable decrease in the efficiency of the Low-Q2 tagger depending on how many threads were asked for. Unit tests for all of the meta factories and functors should be added as an issue to try head this off in the future but outwith this fix. ### What kind of change does this PR introduce? - [x] Bug fix (issue #__) - [ ] New feature (issue #__) - [ ] Documentation update - [ ] Other: __ ### Please check if this PR fulfills the following: - [ ] Tests for the changes have been added - [ ] Documentation has been added / updated - [ ] Changes have been communicated to collaborators ### Does this PR introduce breaking changes? What changes might users need to make to their code? No ### Does this PR change default behavior? All of the Low-Q2 Tagger hits will be converted into clusters rather than just those run on the first thread to call the functor. --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Dmitry Kalinkin <[email protected]>
- Loading branch information
1 parent
0e1566c
commit a894644
Showing
4 changed files
with
22 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters