Skip to content

Define RefProdVector for HGCRecHitCollection and PFRecHitCollection#49190

Merged
cmsbuild merged 4 commits intocms-sw:masterfrom
Electricks94:MultiCollection
Nov 12, 2025
Merged

Define RefProdVector for HGCRecHitCollection and PFRecHitCollection#49190
cmsbuild merged 4 commits intocms-sw:masterfrom
Electricks94:MultiCollection

Conversation

@Electricks94
Copy link
Copy Markdown
Contributor

@Electricks94 Electricks94 commented Oct 20, 2025

This PR adds RefProdVector.h to DataFormats/Common as an alias for std::vector<RefProd<T>>. Then RefProdVectors for PFRecHitCollection and HGCRecHitCollection are introduced as product of the RecHitMapProducer and comsumed by other producers to create a MultiSpan on the fly. This workflow has two advantages

  1. Memory copies are avoided
  2. The order of the Collections is defined in the RefProdVector at one location. Like this later producers can rely on the order (see issue 48526 )

PR validation:

Workflow 29688.0

FYI @felicepantaleo @leobeltra

@cmsbuild
Copy link
Copy Markdown
Contributor

cmsbuild commented Oct 20, 2025

cms-bot internal usage

@cmsbuild
Copy link
Copy Markdown
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-49190/46489

  • Found files with invalid states:

    • CommonTools/RecoAlgos/interface/MultiCollectionManager.h:
  • There are other open Pull requests which might conflict with changes you have proposed:

@cmsbuild
Copy link
Copy Markdown
Contributor

A new Pull Request was created by @Electricks94 for master.

It involves the following packages:

  • DataFormats/Common (core)
  • DataFormats/HGCRecHit (reconstruction)
  • RecoLocalCalo/Configuration (reconstruction)
  • RecoLocalCalo/HGCalRecProducers (reconstruction)
  • Validation/Configuration (dqm, simulation)

@Dr15Jones, @civanch, @cmsbuild, @ctarricone, @gabrielmscampos, @jfernan2, @kpedro88, @makortel, @mandrenguyen, @mdhildreth, @nothingface0, @rseidita, @smuzaffar can you please review it and eventually sign? Thanks.
@IzaakWN, @ReyerBand, @apsallid, @bsunanda, @cseez, @denizsun, @edjtscott, @felicepantaleo, @hatakeyamak, @lecriste, @lgray, @makortel, @missirol, @mmusich, @pfs, @rovere, @salimcerci, @sameasy, @sethzenz, @thomreis, @vandreev11, @wang0jin, @wddgit, @youyingli this is something you requested to watch as well.
@ftenchini, @mandrenguyen, @sextonkennedy you are the release manager for this.

cms-bot commands are listed here

@felicepantaleo
Copy link
Copy Markdown
Contributor

@cmsbuild please test

@cmsbuild
Copy link
Copy Markdown
Contributor

-1

Failed Tests: Build ClangBuild
Size: This PR adds an extra 48KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-2382bf/48727/summary.html
COMMIT: 3bf019b
CMSSW: CMSSW_16_0_X_2025-10-19-2300/el8_amd64_gcc13
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week0/cms-sw/cmssw/49190/48727/install.sh to create a dev area with all the needed externals and cmssw changes.

Build

I found compilation error when building:

/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/gcc/13.4.0-6908cfdf803923e783448096ca4f0923/bin/c++ -c -DCMS_MICRO_ARCH='x86-64-v3' -DGNU_GCC -D_GNU_SOURCE -DTBB_USE_GLIBCXX_VERSION=130400 -DTBB_SUPPRESS_DEPRECATED_MESSAGES -DTBB_PREVIEW_RESUMABLE_TASKS=1 -DTBB_PREVIEW_TASK_GROUP_EXTENSIONS=1 -DBOOST_SPIRIT_THREADSAFE -DPHOENIX_THREADSAFE -DBOOST_MATH_DISABLE_STD_FPCLASSIFY -DBOOST_UUID_RANDOM_PROVIDER_FORCE_POSIX -DBOOST_MPL_IGNORE_PARENTHESES_WARNING -DCMSSW_GIT_HASH='CMSSW_16_0_X_2025-10-19-2300' -DPROJECT_NAME='CMSSW' -DPROJECT_VERSION='CMSSW_16_0_X_2025-10-19-2300' -Isrc -Ipoison -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/cms/cmssw/CMSSW_16_0_X_2025-10-19-2300/src -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/pcre/8.43-6d98fda3bfd074ebb583e2d6a2c75d25/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/boost/1.80.0-f5051ff020fe9f6f1a74162002ac1ea0/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/bz2lib/1.0.6-d113e1c6278c07eeaff5f84db9548446/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/cppunit/1.15.x-d4385f8b2638355b326bc1769bca68f4/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/libuuid/2.34-5ba7a8abfc0c5fecdc448cca360c25ff/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/lcg/root/6.32.13-2ba92f62034c9fcccda180513e8d0814/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tbb/v2022.0.0-ede4a930df4abec602e96e3f3ad15914/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/xz/5.6.4-b9c4ffbc390ed320a5d57fd552e29a05/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/zlib/1.2.13-589f6bb51bbeba38a7adf5a10ea8a093/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/catch2/3.11.0-2e42f64598f571f0c3579816b5de560c/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/md5/1.0.0-26057075013e190e56dad37d35219376/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tinyxml2/6.2.0-67924ead96ecb4e69aad321b767979a5/include -O3 -pthread -pipe -Werror=main -Werror=pointer-arith -Werror=overlength-strings -Wno-vla -Werror=overflow -std=c++20 -ftree-vectorize -Werror=array-bounds -Werror=format-contains-nul -Werror=type-limits -fvisibility-inlines-hidden -fno-math-errno --param vect-max-version-for-alias-checks=50 -Xassembler --compress-debug-sections -Wno-error=array-bounds -Warray-bounds -fuse-ld=bfd -march=x86-64-v3 -felide-constructors -fmessage-length=0 -Wall -Wno-non-template-friend -Wno-long-long -Wreturn-type -Wextra -Wpessimizing-move -Wclass-memaccess -Wno-cast-function-type -Wno-unused-but-set-parameter -Wno-ignored-qualifiers -Wno-unused-parameter -Wunused -Wparentheses -Werror=return-type -Werror=missing-braces -Werror=unused-value -Werror=unused-label -Werror=address -Werror=format -Werror=sign-compare -Werror=write-strings -Werror=delete-non-virtual-dtor -Werror=strict-aliasing -Werror=narrowing -Werror=unused-but-set-variable -Werror=reorder -Werror=unused-variable -Werror=conversion-null -Werror=return-local-addr -Wnon-virtual-dtor -Werror=switch -fdiagnostics-show-option -Wno-unused-local-typedefs -Wno-attributes -Wno-psabi -Wno-error=unused-variable -DBOOST_DISABLE_ASSERTS -flto=auto -fipa-icf -flto-odr-type-merging -fno-fat-lto-objects -Wodr -fPIC -MMD -MF tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_MultiCollection.cpp.d src/DataFormats/Common/test/test_catch2_MultiCollection.cpp -o tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_MultiCollection.cpp.o
>> Compiling  src/DataFormats/Common/test/test_catch2_MultiSpan.cpp
/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/gcc/13.4.0-6908cfdf803923e783448096ca4f0923/bin/c++ -c -DCMS_MICRO_ARCH='x86-64-v3' -DGNU_GCC -D_GNU_SOURCE -DTBB_USE_GLIBCXX_VERSION=130400 -DTBB_SUPPRESS_DEPRECATED_MESSAGES -DTBB_PREVIEW_RESUMABLE_TASKS=1 -DTBB_PREVIEW_TASK_GROUP_EXTENSIONS=1 -DBOOST_SPIRIT_THREADSAFE -DPHOENIX_THREADSAFE -DBOOST_MATH_DISABLE_STD_FPCLASSIFY -DBOOST_UUID_RANDOM_PROVIDER_FORCE_POSIX -DBOOST_MPL_IGNORE_PARENTHESES_WARNING -DCMSSW_GIT_HASH='CMSSW_16_0_X_2025-10-19-2300' -DPROJECT_NAME='CMSSW' -DPROJECT_VERSION='CMSSW_16_0_X_2025-10-19-2300' -Isrc -Ipoison -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/cms/cmssw/CMSSW_16_0_X_2025-10-19-2300/src -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/pcre/8.43-6d98fda3bfd074ebb583e2d6a2c75d25/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/boost/1.80.0-f5051ff020fe9f6f1a74162002ac1ea0/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/bz2lib/1.0.6-d113e1c6278c07eeaff5f84db9548446/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/cppunit/1.15.x-d4385f8b2638355b326bc1769bca68f4/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/libuuid/2.34-5ba7a8abfc0c5fecdc448cca360c25ff/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/lcg/root/6.32.13-2ba92f62034c9fcccda180513e8d0814/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tbb/v2022.0.0-ede4a930df4abec602e96e3f3ad15914/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/xz/5.6.4-b9c4ffbc390ed320a5d57fd552e29a05/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/zlib/1.2.13-589f6bb51bbeba38a7adf5a10ea8a093/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/catch2/3.11.0-2e42f64598f571f0c3579816b5de560c/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/md5/1.0.0-26057075013e190e56dad37d35219376/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tinyxml2/6.2.0-67924ead96ecb4e69aad321b767979a5/include -O3 -pthread -pipe -Werror=main -Werror=pointer-arith -Werror=overlength-strings -Wno-vla -Werror=overflow -std=c++20 -ftree-vectorize -Werror=array-bounds -Werror=format-contains-nul -Werror=type-limits -fvisibility-inlines-hidden -fno-math-errno --param vect-max-version-for-alias-checks=50 -Xassembler --compress-debug-sections -Wno-error=array-bounds -Warray-bounds -fuse-ld=bfd -march=x86-64-v3 -felide-constructors -fmessage-length=0 -Wall -Wno-non-template-friend -Wno-long-long -Wreturn-type -Wextra -Wpessimizing-move -Wclass-memaccess -Wno-cast-function-type -Wno-unused-but-set-parameter -Wno-ignored-qualifiers -Wno-unused-parameter -Wunused -Wparentheses -Werror=return-type -Werror=missing-braces -Werror=unused-value -Werror=unused-label -Werror=address -Werror=format -Werror=sign-compare -Werror=write-strings -Werror=delete-non-virtual-dtor -Werror=strict-aliasing -Werror=narrowing -Werror=unused-but-set-variable -Werror=reorder -Werror=unused-variable -Werror=conversion-null -Werror=return-local-addr -Wnon-virtual-dtor -Werror=switch -fdiagnostics-show-option -Wno-unused-local-typedefs -Wno-attributes -Wno-psabi -Wno-error=unused-variable -DBOOST_DISABLE_ASSERTS -flto=auto -fipa-icf -flto-odr-type-merging -fno-fat-lto-objects -Wodr -fPIC -MMD -MF tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_MultiSpan.cpp.d src/DataFormats/Common/test/test_catch2_MultiSpan.cpp -o tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_MultiSpan.cpp.o
>> Compiling  src/DataFormats/Common/test/test_catch2_OwnVector.cpp
/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/gcc/13.4.0-6908cfdf803923e783448096ca4f0923/bin/c++ -c -DCMS_MICRO_ARCH='x86-64-v3' -DGNU_GCC -D_GNU_SOURCE -DTBB_USE_GLIBCXX_VERSION=130400 -DTBB_SUPPRESS_DEPRECATED_MESSAGES -DTBB_PREVIEW_RESUMABLE_TASKS=1 -DTBB_PREVIEW_TASK_GROUP_EXTENSIONS=1 -DBOOST_SPIRIT_THREADSAFE -DPHOENIX_THREADSAFE -DBOOST_MATH_DISABLE_STD_FPCLASSIFY -DBOOST_UUID_RANDOM_PROVIDER_FORCE_POSIX -DBOOST_MPL_IGNORE_PARENTHESES_WARNING -DCMSSW_GIT_HASH='CMSSW_16_0_X_2025-10-19-2300' -DPROJECT_NAME='CMSSW' -DPROJECT_VERSION='CMSSW_16_0_X_2025-10-19-2300' -Isrc -Ipoison -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/cms/cmssw/CMSSW_16_0_X_2025-10-19-2300/src -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/pcre/8.43-6d98fda3bfd074ebb583e2d6a2c75d25/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/boost/1.80.0-f5051ff020fe9f6f1a74162002ac1ea0/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/bz2lib/1.0.6-d113e1c6278c07eeaff5f84db9548446/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/cppunit/1.15.x-d4385f8b2638355b326bc1769bca68f4/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/libuuid/2.34-5ba7a8abfc0c5fecdc448cca360c25ff/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/lcg/root/6.32.13-2ba92f62034c9fcccda180513e8d0814/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tbb/v2022.0.0-ede4a930df4abec602e96e3f3ad15914/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/xz/5.6.4-b9c4ffbc390ed320a5d57fd552e29a05/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/zlib/1.2.13-589f6bb51bbeba38a7adf5a10ea8a093/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/catch2/3.11.0-2e42f64598f571f0c3579816b5de560c/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/md5/1.0.0-26057075013e190e56dad37d35219376/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tinyxml2/6.2.0-67924ead96ecb4e69aad321b767979a5/include -O3 -pthread -pipe -Werror=main -Werror=pointer-arith -Werror=overlength-strings -Wno-vla -Werror=overflow -std=c++20 -ftree-vectorize -Werror=array-bounds -Werror=format-contains-nul -Werror=type-limits -fvisibility-inlines-hidden -fno-math-errno --param vect-max-version-for-alias-checks=50 -Xassembler --compress-debug-sections -Wno-error=array-bounds -Warray-bounds -fuse-ld=bfd -march=x86-64-v3 -felide-constructors -fmessage-length=0 -Wall -Wno-non-template-friend -Wno-long-long -Wreturn-type -Wextra -Wpessimizing-move -Wclass-memaccess -Wno-cast-function-type -Wno-unused-but-set-parameter -Wno-ignored-qualifiers -Wno-unused-parameter -Wunused -Wparentheses -Werror=return-type -Werror=missing-braces -Werror=unused-value -Werror=unused-label -Werror=address -Werror=format -Werror=sign-compare -Werror=write-strings -Werror=delete-non-virtual-dtor -Werror=strict-aliasing -Werror=narrowing -Werror=unused-but-set-variable -Werror=reorder -Werror=unused-variable -Werror=conversion-null -Werror=return-local-addr -Wnon-virtual-dtor -Werror=switch -fdiagnostics-show-option -Wno-unused-local-typedefs -Wno-attributes -Wno-psabi -Wno-error=unused-variable -DBOOST_DISABLE_ASSERTS -flto=auto -fipa-icf -flto-odr-type-merging -fno-fat-lto-objects -Wodr -fPIC -MMD -MF tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_OwnVector.cpp.d src/DataFormats/Common/test/test_catch2_OwnVector.cpp -o tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_OwnVector.cpp.o
src/DataFormats/Common/test/test_catch2_MultiCollection.cpp:6:10: fatal error: catch.hpp: No such file or directory
    6 | #include 
      |          ^~~~~~~~~~~
compilation terminated.
>> Compiling  src/DataFormats/Common/test/test_catch2_Ref.cpp
/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/gcc/13.4.0-6908cfdf803923e783448096ca4f0923/bin/c++ -c -DCMS_MICRO_ARCH='x86-64-v3' -DGNU_GCC -D_GNU_SOURCE -DTBB_USE_GLIBCXX_VERSION=130400 -DTBB_SUPPRESS_DEPRECATED_MESSAGES -DTBB_PREVIEW_RESUMABLE_TASKS=1 -DTBB_PREVIEW_TASK_GROUP_EXTENSIONS=1 -DBOOST_SPIRIT_THREADSAFE -DPHOENIX_THREADSAFE -DBOOST_MATH_DISABLE_STD_FPCLASSIFY -DBOOST_UUID_RANDOM_PROVIDER_FORCE_POSIX -DBOOST_MPL_IGNORE_PARENTHESES_WARNING -DCMSSW_GIT_HASH='CMSSW_16_0_X_2025-10-19-2300' -DPROJECT_NAME='CMSSW' -DPROJECT_VERSION='CMSSW_16_0_X_2025-10-19-2300' -Isrc -Ipoison -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/cms/cmssw/CMSSW_16_0_X_2025-10-19-2300/src -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/pcre/8.43-6d98fda3bfd074ebb583e2d6a2c75d25/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/boost/1.80.0-f5051ff020fe9f6f1a74162002ac1ea0/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/bz2lib/1.0.6-d113e1c6278c07eeaff5f84db9548446/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/cppunit/1.15.x-d4385f8b2638355b326bc1769bca68f4/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/libuuid/2.34-5ba7a8abfc0c5fecdc448cca360c25ff/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/lcg/root/6.32.13-2ba92f62034c9fcccda180513e8d0814/include -isystem/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tbb/v2022.0.0-ede4a930df4abec602e96e3f3ad15914/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/xz/5.6.4-b9c4ffbc390ed320a5d57fd552e29a05/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/zlib/1.2.13-589f6bb51bbeba38a7adf5a10ea8a093/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/catch2/3.11.0-2e42f64598f571f0c3579816b5de560c/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/md5/1.0.0-26057075013e190e56dad37d35219376/include -I/cvmfs/cms-ib.cern.ch/sw/x86_64/nweek-02912/el8_amd64_gcc13/external/tinyxml2/6.2.0-67924ead96ecb4e69aad321b767979a5/include -O3 -pthread -pipe -Werror=main -Werror=pointer-arith -Werror=overlength-strings -Wno-vla -Werror=overflow -std=c++20 -ftree-vectorize -Werror=array-bounds -Werror=format-contains-nul -Werror=type-limits -fvisibility-inlines-hidden -fno-math-errno --param vect-max-version-for-alias-checks=50 -Xassembler --compress-debug-sections -Wno-error=array-bounds -Warray-bounds -fuse-ld=bfd -march=x86-64-v3 -felide-constructors -fmessage-length=0 -Wall -Wno-non-template-friend -Wno-long-long -Wreturn-type -Wextra -Wpessimizing-move -Wclass-memaccess -Wno-cast-function-type -Wno-unused-but-set-parameter -Wno-ignored-qualifiers -Wno-unused-parameter -Wunused -Wparentheses -Werror=return-type -Werror=missing-braces -Werror=unused-value -Werror=unused-label -Werror=address -Werror=format -Werror=sign-compare -Werror=write-strings -Werror=delete-non-virtual-dtor -Werror=strict-aliasing -Werror=narrowing -Werror=unused-but-set-variable -Werror=reorder -Werror=unused-variable -Werror=conversion-null -Werror=return-local-addr -Wnon-virtual-dtor -Werror=switch -fdiagnostics-show-option -Wno-unused-local-typedefs -Wno-attributes -Wno-psabi -Wno-error=unused-variable -DBOOST_DISABLE_ASSERTS -flto=auto -fipa-icf -flto-odr-type-merging -fno-fat-lto-objects -Wodr -fPIC -MMD -MF tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_Ref.cpp.d src/DataFormats/Common/test/test_catch2_Ref.cpp -o tmp/el8_amd64_gcc13/src/DataFormats/Common/test/testDataFormatsCommonCatch2/test_catch2_Ref.cpp.o


Clang Build

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

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

>> Creating project symlinks
>> Entering Package DataFormats/Common
>> Entering Package DataFormats/HGCRecHit
>> Entering Package RecoLocalCalo/HGCalRecProducers
>> Compile sequence completed for CMSSW CMSSW_16_0_X_2025-10-19-2300
gmake: *** [There are compilation/build errors. Please see the detail log above.] Error 1
Command exited with non-zero status 1
	Command being timed: "scram build -k -j 32 COMPILER=llvm compile BUILD_LOG=yes"
	User time (seconds): 437.95
	System time (seconds): 58.06
	Percent of CPU this job got: 811%


@Dr15Jones
Copy link
Copy Markdown
Contributor

@Electricks94 the simplest fix is to change to catch2/catch_all.hpp and compile using a very recent IB.

@cmsbuild
Copy link
Copy Markdown
Contributor

Pull request #49190 was updated.


from Configuration.ProcessModifiers.ticl_barrel_cff import ticl_barrel
ticl_barrel.toModify(recHitMapProducer, hits = hits, hgcalOnly = False)
ticl_barrel.toModify(recHitMapProducer, hits = hits, hgcalOnly = False) No newline at end of file
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

missing EOL

@cmsbuild
Copy link
Copy Markdown
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-49190/46608

@cmsbuild
Copy link
Copy Markdown
Contributor

Pull request #49190 was updated.

@Electricks94
Copy link
Copy Markdown
Contributor Author

type ngt

@felicepantaleo
Copy link
Copy Markdown
Contributor

felicepantaleo commented Oct 30, 2025

hi @Electricks94 , I would prefer that you define the MultiCollection<T> as
std::vector<edm::RefProd<T>>, rather than using overly specialized names for each kind of collection.

@cmsbuild
Copy link
Copy Markdown
Contributor

-code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-49190/46614

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

@cmsbuild
Copy link
Copy Markdown
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-49190/46615

@cmsbuild
Copy link
Copy Markdown
Contributor

Pull request #49190 was updated.

const auto hits = iEvent.get(hitsToken_);
for (std::size_t index = 0; const auto& hgcRecHitCollection : hits) {
if (hgcRecHitCollection->empty()) {
edm::LogWarning("AllHitToTracksterAssociatorsProducer") << "HGCRecHitCollections #" << index << " is not valid.";
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

The producers, that have been adapted in the PR contain a few debug evaluations. They have not beed guarded by NDEBUG so far, should this be done?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Guarding with NDEBUG won't have much effect in practice because by default CMSSW is built with NDEBUG defined.


namespace edm {
template <typename T>
using MultiCollection = std::vector<edm::RefProd<T>>;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Repeating #49190 (comment) I still find the MultiCollection not to be a very descriptive name. How about e.g. RefProdVector?

@makortel
Copy link
Copy Markdown
Contributor

I'd still ask a test for a case where (at least) one of the RefProd elements in the MultiCollection is Null or not Available when passed to MultiSpan constructor.

@cmsbuild
Copy link
Copy Markdown
Contributor

+code-checks

Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-49190/46629

@cmsbuild
Copy link
Copy Markdown
Contributor

Pull request #49190 was updated.

@Electricks94
Copy link
Copy Markdown
Contributor Author

I'd still ask a test for a case where (at least) one of the RefProd elements in the MultiCollection is Null or not Available when passed to MultiSpan constructor.

Sorry about that, I forgot to add the comment after the bigger changes to the former MultiCollection. I added a nullptr to the test_catch2_MultiSpan and check for isNonnull when constructing the MultiSpan. Similarly to the add function I just skip the RefProds that are nullptr. Would it be reasonable to add a warning here?

@makortel
Copy link
Copy Markdown
Contributor

Thanks!

Similarly to the add function I just skip the RefProds that are nullptr.

I guess a Null, i.e. default-constructed, RefProd makes sense to be ignored in the same way as empty span.

Ideally a test for non-Available would be nice, but mocking that case would be a bit complicated, and should throw an exception, so maybe we can live without.

Would it be reasonable to add a warning here?

I don't think a warning would be useful because nobody looks at them (except possibly during local development). Or in other words, behavior should be such that it makes sense without having look at logs.

@makortel
Copy link
Copy Markdown
Contributor

@cmsbuild, please test

@cmsbuild
Copy link
Copy Markdown
Contributor

+1

Size: This PR adds an extra 16KB to repository
Summary: https://cmssdt.cern.ch/SDT/jenkins-artifacts/pull-request-integration/PR-2382bf/49127/summary.html
COMMIT: dbe55da
CMSSW: CMSSW_16_0_X_2025-10-31-1100/el8_amd64_gcc13
User test area: For local testing, you can use /cvmfs/cms-ci.cern.ch/week1/cms-sw/cmssw/49190/49127/install.sh to create a dev area with all the needed externals and cmssw changes.

Comparison Summary

Summary:

@gabrielmscampos
Copy link
Copy Markdown
Member

+dqm

@jfernan2
Copy link
Copy Markdown
Contributor

+1

@makortel
Copy link
Copy Markdown
Contributor

+core

(I read the non-core code only superficially)

@civanch
Copy link
Copy Markdown
Contributor

civanch commented Nov 12, 2025

+1

@cmsbuild
Copy link
Copy Markdown
Contributor

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. @sextonkennedy, @mandrenguyen, @ftenchini (and backports should be raised in the release meeting by the corresponding L2)

@mandrenguyen
Copy link
Copy Markdown
Contributor

+1

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.

10 participants