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

[UBSAN] Fix unit test by feeding it with correct input #35465

Merged
merged 1 commit into from Oct 7, 2021

Conversation

smuzaffar
Copy link
Contributor

Unit test testUCTUnpacker requires valid input to run. In UBSAN IBs it fails [a] as the stdin is closed and no data is feed to the test which resulted in creating UCTAMCRawData with undefined data.

This PR proposes to use https://github.com/cms-sw/cmssw/blob/master/EventFilter/L1TXRawToDigi/test/event_test1.txt as input. Local test in UBSAN IBs shows no failure.

[a] https://cmssdt.cern.ch/SDT/cgi-bin/logreader/slc7_amd64_gcc10/CMSSW_12_1_UBSAN_X_2021-09-27-2300/unitTestLogs/EventFilter/L1TXRawToDigi#/

AMC Payload Header:
Data Length.. = 318408
BXID......... = 36
L1ID......... = 00000000
AMC No ...... = 0
Layer-1 Phi.. = 58432
Orbit No..... = 50225
AMC Payload Trailer:

 *** Break *** segmentation violation
Data Length.. = 


===========================================================
There was a crash.
This is the entire stack trace of all threads:
===========================================================
#0  0x00002af6b117a4fc in waitpid () from /lib64/libc.so.6
#1  0x00002af6b10f7f62 in do_system () from /lib64/libc.so.6
#2  0x00002af6b0098f9b in TUnixSystem::StackTrace() () from /cvmfs/cms-ib.cern.ch/nweek-02700/slc7_amd64_gcc10/cms/cmssw/CMSSW_12_1_UBSAN_X_2021-09-27-2300/external/slc7_amd64_gcc10/lib/libCore.so
#3  0x00002af6b0096555 in TUnixSystem::DispatchSignals(ESignals) () from /cvmfs/cms-ib.cern.ch/nweek-02700/slc7_amd64_gcc10/cms/cmssw/CMSSW_12_1_UBSAN_X_2021-09-27-2300/external/slc7_amd64_gcc10/lib/libCore.so
#4  <signal handler called>
#5  0x000000000041e602 in UCTAMCRawData::print() ()
#6  0x00000000004058a6 in main ()
===========================================================

@smuzaffar
Copy link
Contributor Author

please test

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-35465/25620

  • This PR adds an extra 12KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @smuzaffar (Malik Shahzad Muzaffar) for master.

It involves the following packages:

  • EventFilter/L1TXRawToDigi (l1)

@rekovic, @cecilecaillol can you please review it and eventually sign? Thanks.
@Martin-Grunewald, @missirol, @battibass this is something you requested to watch as well.
@perrotta, @dpiparo, @qliphy you are the release manager for this.

cms-bot commands are listed here

@smuzaffar
Copy link
Contributor Author

smuzaffar commented Sep 29, 2021

please test for CMSSW_12_1_UBSAN_X

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-b037f8/19224/summary.html
COMMIT: 09b75e7
CMSSW: CMSSW_12_1_X_2021-09-28-2300/slc7_amd64_gcc900
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/35465/19224/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: 10 differences found in the comparisons
  • DQMHistoTests: Total files compared: 40
  • DQMHistoTests: Total histograms compared: 3211080
  • DQMHistoTests: Total failures: 6
  • DQMHistoTests: Total nulls: 0
  • DQMHistoTests: Total successes: 3211052
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: 0.0 KiB( 39 files compared)
  • Checked 169 log files, 37 edm output root files, 40 DQM output files
  • TriggerResults: no differences found

@cmsbuild
Copy link
Contributor

+1

Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-b037f8/19225/summary.html
COMMIT: 09b75e7
CMSSW: CMSSW_12_1_UBSAN_X_2021-09-27-2300/slc7_amd64_gcc10
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/35465/19225/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

  • You potentially added 21473 lines to the logs
  • Reco comparison results: 66375 differences found in the comparisons
  • DQMHistoTests: Total files compared: 40
  • DQMHistoTests: Total histograms compared: 3211080
  • DQMHistoTests: Total failures: 415437
  • DQMHistoTests: Total nulls: 14
  • DQMHistoTests: Total successes: 2795607
  • DQMHistoTests: Total skipped: 22
  • DQMHistoTests: Total Missing objects: 0
  • DQMHistoSizes: Histogram memory added: -0.162 KiB( 39 files compared)
  • DQMHistoSizes: changed ( 10224.0 ): 0.117 KiB SiStrip/MechanicalView
  • DQMHistoSizes: changed ( 136.731,... ): 0.004 KiB JetMET/SUSYDQM
  • DQMHistoSizes: changed ( 250202.181 ): -0.533 KiB SiStrip/MechanicalView
  • DQMHistoSizes: changed ( 25202.0 ): 0.246 KiB SiStrip/MechanicalView
  • Checked 169 log files, 37 edm output root files, 40 DQM output files
  • TriggerResults: found differences in 14 / 39 workflows

@smuzaffar
Copy link
Contributor Author

@cms-sw/l1-l2 , can you please review this?

@smuzaffar
Copy link
Contributor Author

@cms-sw/l1-l2 . note that this tests hangs when run interactively using scram build runtests as it waits for input via stdin

@rekovic
Copy link
Contributor

rekovic commented Oct 6, 2021

+1

@cmsbuild
Copy link
Contributor

cmsbuild commented Oct 6, 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. @perrotta, @dpiparo, @qliphy (and backports should be raised in the release meeting by the corresponding L2)

@perrotta
Copy link
Contributor

perrotta commented Oct 7, 2021

+1

@cmsbuild cmsbuild merged commit d14b3f7 into cms-sw:master Oct 7, 2021
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

4 participants