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

Replace boost/regex.hpp with standard library regex #35919

Closed
wants to merge 1 commit into from
Closed

Replace boost/regex.hpp with standard library regex #35919

wants to merge 1 commit into from

Conversation

guitargeek
Copy link
Contributor

@guitargeek guitargeek commented Oct 31, 2021

PR description:

Title says it all: a boost feature is replaced with the corresponding standard library feature.

PR validation:

CMSSW compiles.

if this PR is a backport please specify the original PR and why you need to backport that PR:

No backport intended.

@cmsbuild cmsbuild added this to the CMSSW_12_2_X milestone Oct 31, 2021
@guitargeek
Copy link
Contributor Author

Something went wrong with the daylight saving time transition I guess... I'll try to force push again

@cmsbuild
Copy link
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-35919/26324

  • This PR adds an extra 140KB to repository

@cmsbuild
Copy link
Contributor

A new Pull Request was created by @guitargeek (Jonas Rembser) for master.

It involves the following packages:

  • CalibTracker/SiStripCommon (alca)
  • Calibration/HcalAlCaRecoProducers (alca)
  • CommonTools/Utils (reconstruction)
  • DQM/HLTEvF (dqm, hlt)
  • DQMOffline/Trigger (dqm)
  • DQMServices/StreamerIO (dqm)
  • DataFormats/PatCandidates (reconstruction)
  • EventFilter/L1TRawToDigi (l1)
  • Fireworks/Core (visualization)
  • HLTrigger/Timer (hlt)
  • JetMETCorrections/IsolatedParticles (analysis)
  • PhysicsTools/FWLite (analysis)
  • RecoLocalTracker/SiPixelRecHits (reconstruction)
  • RecoLuminosity/LumiProducer (reconstruction)
  • RecoTracker/FinalTrackSelectors (reconstruction)
  • TrackingTools/TrackAssociator (reconstruction)

@malbouis, @alja, @yuanchao, @rekovic, @makortel, @pmandrik, @emanueleusai, @ahmad3213, @tvami, @cmsbuild, @missirol, @Dr15Jones, @jfernan2, @Martin-Grunewald, @slava77, @jpata, @francescobrivio, @santocch, @cecilecaillol, @pbo0, @rvenditti can you please review it and eventually sign? Thanks.
@echabert, @rappoccio, @gouskos, @felicepantaleo, @hatakeyamak, @robervalwalsh, @CeliaFernandez, @Martin-Grunewald, @bsunanda, @OzAmram, @thomreis, @ahinzmann, @missirol, @threus, @mmusich, @seemasharmafnal, @mmarionncern, @calderona, @silviodonato, @JanFSchulte, @jhgoh, @jdolen, @HuguesBrun, @cericeci, @ferencek, @pieterdavid, @rociovilar, @sscruz, @abbiendi, @barvic, @GiacomoSguazzoni, @rovere, @VinInn, @jdamgov, @dinyar, @nhanvtran, @gkasieczka, @tocheng, @schoef, @ebrondol, @mtosi, @dgulhan, @clelange, @bellan, @trocino, @gbenelli, @Fedespring, @alja, @dkotlins, @lecriste, @cbernet, @gpetruc, @mariadalfonso, @tvami 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

@tvami
Copy link
Contributor

tvami commented Oct 31, 2021

@cmsbuild , please test

@cmsbuild
Copy link
Contributor

-1

Failed Tests: RelVals RelVals-INPUT AddOn
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-0f3b8e/20114/summary.html
COMMIT: f971bcf
CMSSW: CMSSW_12_2_X_2021-10-31-0000/slc7_amd64_gcc900
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/35919/20114/install.sh to create a dev area with all the needed externals and cmssw changes.

CMS StaticAnalyzer warnings: There are 1 inherits from legacy modules warnings. See https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-0f3b8e/20114/llvm-analysis/legacy-mod-sa.txt for details.

RelVals

----- Begin Fatal Exception 31-Oct-2021 12:48:24 CET-----------------------
An exception of category 'EventSetupConflict' occurred while
   [0] Calling beginJob
Exception Message:
two EventSetup Sources want to deliver type="PPSAssociationCuts" label=""
 from record PPSAssociationCutsRcd. The two providers are 
1) type="PPSAssociationCutsESSource" label="ppsAssociationCutsESSource"
2) type="PoolDBESSource" label="GlobalTag"
Please either
   remove one of these Sources
   or find a way of configuring one of them so it does not deliver this data
   or use an es_prefer statement in the configuration to choose one.
----- End Fatal Exception -------------------------------------------------
----- Begin Fatal Exception 31-Oct-2021 12:49:01 CET-----------------------
An exception of category 'EventSetupConflict' occurred while
   [0] Calling beginJob
Exception Message:
two EventSetup Sources want to deliver type="PPSAssociationCuts" label=""
 from record PPSAssociationCutsRcd. The two providers are 
1) type="PPSAssociationCutsESSource" label="ppsAssociationCutsESSource"
2) type="PoolDBESSource" label="GlobalTag"
Please either
   remove one of these Sources
   or find a way of configuring one of them so it does not deliver this data
   or use an es_prefer statement in the configuration to choose one.
----- End Fatal Exception -------------------------------------------------
----- Begin Fatal Exception 31-Oct-2021 12:49:01 CET-----------------------
An exception of category 'EventSetupConflict' occurred while
   [0] Calling beginJob
Exception Message:
two EventSetup Sources want to deliver type="PPSAssociationCuts" label=""
 from record PPSAssociationCutsRcd. The two providers are 
1) type="PPSAssociationCutsESSource" label="ppsAssociationCutsESSource"
2) type="PoolDBESSource" label="GlobalTag"
Please either
   remove one of these Sources
   or find a way of configuring one of them so it does not deliver this data
   or use an es_prefer statement in the configuration to choose one.
----- End Fatal Exception -------------------------------------------------
Expand to see more relval errors ...

RelVals-INPUT

  • 4.64.6_MinimumBias2010A+MinimumBias2010A+RECOSKIMALCA+HARVESTDR1/step2_MinimumBias2010A+MinimumBias2010A+RECOSKIMALCA+HARVESTDR1.log
  • 136.72411136.72411_RunJetHT2016B_reminiaodUL+RunJetHT2016B_reminiaodUL+REMINIAOD_data2016UL_HIPM+HARVESTDR2_REMINIAOD_data2016UL_HIPM/step2_RunJetHT2016B_reminiaodUL+RunJetHT2016B_reminiaodUL+REMINIAOD_data2016UL_HIPM+HARVESTDR2_REMINIAOD_data2016UL_HIPM.log
  • 136.72412136.72412_RunJetHT2016B_reminiaodUL+RunJetHT2016B_reminiaodUL+REMININANO_data2016UL_HIPM+HARVESTDR2_REMININANO_data2016UL_HIPM/step2_RunJetHT2016B_reminiaodUL+RunJetHT2016B_reminiaodUL+REMININANO_data2016UL_HIPM+HARVESTDR2_REMININANO_data2016UL_HIPM.log
Expand to see more relval errors ...

AddOn Tests

----- Begin Fatal Exception 31-Oct-2021 12:45:37 CET-----------------------
An exception of category 'EventSetupConflict' occurred while
   [0] Calling beginJob
Exception Message:
two EventSetup Sources want to deliver type="PPSAssociationCuts" label=""
 from record PPSAssociationCutsRcd. The two providers are 
1) type="PPSAssociationCutsESSource" label="ppsAssociationCutsESSource"
2) type="PoolDBESSource" label="GlobalTag"
Please either
   remove one of these Sources
   or find a way of configuring one of them so it does not deliver this data
   or use an es_prefer statement in the configuration to choose one.
----- End Fatal Exception -------------------------------------------------
----- Begin Fatal Exception 31-Oct-2021 12:45:38 CET-----------------------
An exception of category 'EventSetupConflict' occurred while
   [0] Calling beginJob
Exception Message:
two EventSetup Sources want to deliver type="PPSAssociationCuts" label=""
 from record PPSAssociationCutsRcd. The two providers are 
1) type="PPSAssociationCutsESSource" label="ppsAssociationCutsESSource"
2) type="PoolDBESSource" label="GlobalTag"
Please either
   remove one of these Sources
   or find a way of configuring one of them so it does not deliver this data
   or use an es_prefer statement in the configuration to choose one.
----- End Fatal Exception -------------------------------------------------
----- Begin Fatal Exception 31-Oct-2021 12:49:32 CET-----------------------
An exception of category 'EventSetupConflict' occurred while
   [0] Calling beginJob
Exception Message:
two EventSetup Sources want to deliver type="PPSAssociationCuts" label=""
 from record PPSAssociationCutsRcd. The two providers are 
1) type="PPSAssociationCutsESSource" label="ppsAssociationCutsESSource"
2) type="PoolDBESSource" label="GlobalTag"
Please either
   remove one of these Sources
   or find a way of configuring one of them so it does not deliver this data
   or use an es_prefer statement in the configuration to choose one.
----- End Fatal Exception -------------------------------------------------
Expand to see more addon errors ...

@slava77
Copy link
Contributor

slava77 commented Oct 31, 2021

@cmsbuild please test with #35766

@qliphy qliphy added this to the CMSSW_12_4_X milestone Mar 24, 2022
@qliphy
Copy link
Contributor

qliphy commented Mar 24, 2022

@guitargeek I notice this is reopened while the milestone is still 12_2_X. I have changed it to 12_4_X which is current master.

@jpata
Copy link
Contributor

jpata commented Mar 24, 2022

@guitargeek do you plan to work on this, should we review?

@guitargeek
Copy link
Contributor Author

Yes I plan to work on this, because I realized now how we can fix the problem with the slow regex that @davidlange6 mentioned: #35919 (comment) (because I had a similar problem in RooFit: root-project/root#10205).

The construction of std::regex objects is expensive because the regex needs to be compiled, and this compile cost seems to be higher for the std:: than the boost implementation. If we about compiling a single regex multiple times by making it static const, we can make the regex compile time negligible and then it doesn't matter if we use boost or std::regex (and then this PR will also bring a speedup in workflows with many regex).

@guitargeek
Copy link
Contributor Author

So I plan to update this PR turning the std::regex to static const std::regex.

@yuanchao
Copy link
Contributor

@guitargeek Did you test the performance for the static const case? Let us know when this PR is ready for review.

@tvami
Copy link
Contributor

tvami commented Apr 5, 2022

Hi @guitargeek do you maybe have an update on this? Thanks!

@jpata
Copy link
Contributor

jpata commented Apr 14, 2022

just a kind ping on this.

@cecilecaillol
Copy link
Contributor

+l1

@mmusich
Copy link
Contributor

mmusich commented Apr 14, 2022

@cmsbuild
Copy link
Contributor

Pull request has been put on hold by @mmusich
They need to issue an unhold command to remove the hold state or L1 can unhold it for all

@cmsbuild cmsbuild added the hold label Apr 14, 2022
@tvami
Copy link
Contributor

tvami commented Apr 21, 2022

A kind ping to @guitargeek , could you please let us know the ETA for the change of std::regex to static const std::regex?

@tvami
Copy link
Contributor

tvami commented May 2, 2022

-alca

  • to remove from the alca queues, we'll resign when the std::regex is dealt with

@alja
Copy link
Contributor

alja commented May 2, 2022

+1

@emanueleusai
Copy link
Member

-1

removing from DQM queues. We'll resign when the std::regex is dealt with

@jpata
Copy link
Contributor

jpata commented May 9, 2022

-reconstruction

  • removing from reco queues until it's updated

@guitargeek
Copy link
Contributor Author

Closing again because of lack of time :(

@guitargeek guitargeek closed this May 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment