It is a bit confusing that there is no proper way to make sure an update from gcc-toolset-11 to gcc-toolset-12 is correct. Several previous gcc-toolset-X are no longer available and/or now use system versions. It would be desirable to run: # dnf install gcc-toolset-12-toolchain to make sure every dependency is in place, and then run: #scl enable gcc-toolset-12 bash to make sure to be using the proper environment.
I removed gcc-toolset-12-toolchain because it no longer made sense; the perftools packages were dropped from GTS. $ dnf install gcc-toolset-12 should install all GTS 12 packages.
Thanks. I understand now how to make sure to be using the proper environment!