Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use ServiceWeakToken with asynchronous tasks #33330

Merged
merged 5 commits into from Apr 5, 2021

Conversation

Dr15Jones
Copy link
Contributor

PR description:

PR validation:

All framework unit tests pass.

Make sure ServiceToken remains alive during asynchronous calls.
To avoid the case where a tbb task lives beyond the lifetime of the EventProcessor, we need to avoid having the Services being held alive by the lambdas.
@Dr15Jones
Copy link
Contributor Author

@dan131riley this is the implementation I finally decided upon, replacing the one to which I pointed you.

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 2, 2021

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-33330/21880

  • This PR adds an extra 96KB to repository

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 2, 2021

A new Pull Request was created by @Dr15Jones (Chris Jones) for master.

It involves the following packages:

FWCore/Framework
FWCore/ServiceRegistry

@makortel, @smuzaffar, @cmsbuild, @Dr15Jones can you please review it and eventually sign? Thanks.
@makortel, @wddgit, @fwyzard this is something you requested to watch as well.
@silviodonato, @dpiparo, @qliphy you are the release manager for this.

cms-bot commands are listed here

@Dr15Jones
Copy link
Contributor Author

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 3, 2021

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-cd92ed/13983/summary.html
COMMIT: 2fabe96
CMSSW: CMSSW_11_3_X_2021-04-02-1100/slc7_amd64_gcc900
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/33330/13983/install.sh to create a dev area with all the needed externals and cmssw changes.

The following merge commits were also included on top of IB + this PR after doing git cms-merge-topic:

You can see more details here:
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-cd92ed/13983/git-recent-commits.json
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-cd92ed/13983/git-merge-result

Comparison Summary

Summary:

  • No significant changes to the logs found
  • Reco comparison results: 3 differences found in the comparisons
  • DQMHistoTests: Total files compared: 37
  • DQMHistoTests: Total histograms compared: 2640868
  • DQMHistoTests: Total failures: 6
  • DQMHistoTests: Total nulls: 1
  • DQMHistoTests: Total successes: 2640839
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.004 KiB( 36 files compared)
  • DQMHistoSizes: changed ( 312.0 ): 0.004 KiB MessageLogger/Warnings
  • Checked 155 log files, 37 edm output root files, 37 DQM output files
  • TriggerResults: no differences found

Dan Riley and others added 2 commits April 4, 2021 10:41
@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 4, 2021

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-33330/21882

  • This PR adds an extra 120KB to repository

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 4, 2021

Pull request #33330 was updated. @smuzaffar, @Dr15Jones, @makortel, @cmsbuild, @Martin-Grunewald, @fwyzard can you please check and sign again.

@Dr15Jones
Copy link
Contributor Author

please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 4, 2021

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-cd92ed/13991/summary.html
COMMIT: 9cf7351
CMSSW: CMSSW_11_3_X_2021-04-04-0000/slc7_amd64_gcc900
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/33330/13991/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • No significant changes to the logs found
  • Reco comparison results: 0 differences found in the comparisons
  • DQMHistoTests: Total files compared: 37
  • DQMHistoTests: Total histograms compared: 2640868
  • DQMHistoTests: Total failures: 1
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 2640845
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 36 files compared)
  • Checked 155 log files, 37 edm output root files, 37 DQM output files
  • TriggerResults: no differences found

@Martin-Grunewald
Copy link
Contributor

+1

@@ -771,6 +771,11 @@ namespace edm {

if (not threadTracker_) {
threadTracker_ = std::make_unique<ThreadTracker>();
iReg.watchPostEndJob([]() {
if (threadTracker_) {
Copy link
Contributor

@makortel makortel Apr 5, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering how this gets captured with empty [] (even if it appears to compile here).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

weird indeed

Copy link
Contributor Author

@Dr15Jones Dr15Jones Apr 5, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

threadTracker_ is static so no this pointer is needed.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@makortel
Copy link
Contributor

makortel commented Apr 5, 2021

+1

@cmsbuild
Copy link
Contributor

cmsbuild commented Apr 5, 2021

This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @silviodonato, @dpiparo, @qliphy (and backports should be raised in the release meeting by the corresponding L2)

@qliphy
Copy link
Contributor

qliphy commented Apr 5, 2021

+1

@cmsbuild cmsbuild merged commit fbb75ea into cms-sw:master Apr 5, 2021
@Dr15Jones Dr15Jones deleted the tryServiceWeakTokenFixForTBB branch April 19, 2021 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants