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

[DataFormats/PatCandidates] Rework statics in header file. #30499

Merged
merged 1 commit into from Jul 4, 2020

Conversation

vgvassilev
Copy link
Contributor

Static variables have internal linkage (http://eel.is/c++draft/basic.link#3.1) and if used in a header file cause ODR violation as every traslation unit will get a different definition of the same entity.

This should address a bug discovered with the CXXMODULE build.

cc: @davidlange6

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

The code-checks are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

The code-checks are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

-code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-30499/16688

Code check has found code style and quality issues which could be resolved by applying following patch(s)

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

The code-checks are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-30499/16692

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

A new Pull Request was created by @vgvassilev (Vassil Vassilev) for master.

It involves the following packages:

DataFormats/PatCandidates

@perrotta, @cmsbuild, @santocch, @slava77 can you please review it and eventually sign? Thanks.
@gouskos, @hatakeyamak, @rovere, @cbernet, @gpetruc, @peruzzim this is something you requested to watch as well.
@silviodonato, @dpiparo you are the release manager for this.

cms-bot commands are listed here

@slava77
Copy link
Contributor

slava77 commented Jul 2, 2020

@cmsbuild please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

The tests are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

-1

Tested at: 96d5d1b

CMSSW: CMSSW_11_2_X_2020-07-01-2300
SCRAM_ARCH: slc7_amd64_gcc820

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-49e10f/7608/git-log-recent-commits
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-49e10f/7608/git-merge-result

You can see the results of the tests here:
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-49e10f/7608/summary.html

I found follow errors while testing this PR

Failed tests: Build ClangBuild

  • Build:

I found compilation error when building:

In file included from /data/cmsbld/jenkins/workspace/ib-run-pr-tests/CMSSW_11_2_X_2020-07-01-2300/src/DataFormats/PatCandidates/interface/Lepton.h:22,
                 from /data/cmsbld/jenkins/workspace/ib-run-pr-tests/CMSSW_11_2_X_2020-07-01-2300/src/DataFormats/PatCandidates/interface/Muon.h:28,
                 from /data/cmsbld/jenkins/workspace/ib-run-pr-tests/CMSSW_11_2_X_2020-07-01-2300/src/PhysicsTools/PatAlgos/test/private/PATUserDataTestModule.cc:33:
/data/cmsbld/jenkins/workspace/ib-run-pr-tests/CMSSW_11_2_X_2020-07-01-2300/src/DataFormats/PatCandidates/interface/PATObject.h: In instantiation of 'const string& pat::PATObject::userDataObjectType(const string&) const [with ObjectType = reco::Muon; std::__cxx11::string = std::__cxx11::basic_string]':
/data/cmsbld/jenkins/workspace/ib-run-pr-tests/CMSSW_11_2_X_2020-07-01-2300/src/PhysicsTools/PatAlgos/test/private/PATUserDataTestModule.cc:144:77:   required from here
/data/cmsbld/jenkins/workspace/ib-run-pr-tests/CMSSW_11_2_X_2020-07-01-2300/src/DataFormats/PatCandidates/interface/PATObject.h:332:54: error: returning reference to temporary [-Werror=return-local-addr]
       return (data != nullptr ? data->typeName() : "");
                                                      ^
cc1plus: some warnings being treated as errors
gmake: *** [tmp/slc7_amd64_gcc820/src/PhysicsTools/PatAlgos/test/PhysicsToolsPatAlgos_testAnalyzers/private/PATUserDataTestModule.cc.o] Error 1
>> Building  edm plugin tmp/slc7_amd64_gcc820/src/PhysicsTools/PatAlgos/test/PhysicsToolsPatAlgos_testAnalyzers/libPhysicsToolsPatAlgos_testAnalyzers.so

  • Clang:

I found compilation warning while trying to compile with clang. Command used:

USER_CUDA_FLAGS='--expt-relaxed-constexpr' USER_CXXFLAGS='-Wno-register -fsyntax-only' scram build -k -j 32 COMPILER='llvm compile'

See details on the summary page.

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-49e10f/7608/git-log-recent-commits
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-49e10f/7608/git-merge-result

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

Comparison not run due to Build errors (RelVals and Igprof tests were also skipped)

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

The code-checks are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-30499/16701

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

Pull request #30499 was updated. @perrotta, @cmsbuild, @santocch, @slava77 can you please check and sign again.

@slava77
Copy link
Contributor

slava77 commented Jul 2, 2020

@cmsbuild please test

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

The tests are being triggered in jenkins.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

+1
Tested at: 63edfe1
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-49e10f/7628/summary.html
CMSSW: CMSSW_11_2_X_2020-07-02-1100
SCRAM_ARCH: slc7_amd64_gcc820

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-49e10f/7628/git-log-recent-commits
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-49e10f/7628/git-merge-result

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 2, 2020

Comparison job queued.

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 3, 2020

Comparison is ready
https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-49e10f/7628/summary.html

Comparison Summary:

  • No significant changes to the logs found
  • Reco comparison results: 4 differences found in the comparisons
  • DQMHistoTests: Total files compared: 37
  • DQMHistoTests: Total histograms compared: 2784120
  • DQMHistoTests: Total failures: 5
  • DQMHistoTests: Total nulls: 1
  • DQMHistoTests: Total successes: 2784064
  • DQMHistoTests: Total skipped: 50
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: -0.004 KiB( 36 files compared)
  • DQMHistoSizes: changed ( 10224.0 ): -0.004 KiB MessageLogger/Warnings
  • Checked 154 log files, 17 edm output root files, 37 DQM output files

@santocch
Copy link

santocch commented Jul 3, 2020

+1

@slava77
Copy link
Contributor

slava77 commented Jul 3, 2020

+1

for #30499 63edfe1

  • technical, in line with the PR description

@cmsbuild
Copy link
Contributor

cmsbuild commented Jul 3, 2020

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 (and backports should be raised in the release meeting by the corresponding L2)

@silviodonato silviodonato changed the title Rework statics in header file. [DataFormats/PatCandidates] Rework statics in header file. Jul 4, 2020
@silviodonato
Copy link
Contributor

+1

@cmsbuild cmsbuild merged commit e5731bb into cms-sw:master Jul 4, 2020
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

6 participants