I realized the default build type for CMakePackage in spack is build_type [RelWithDebInfo].
That's cool (I do the same for my projects) because -g comes with no real (runtime) cost and adds understanding on crashes; but there is an important detail: due to legacy reasons, most compilers are set up with -O2 on that build type:
BLAST-WarpX/warpx#1201
BLAST-WarpX/warpx#1203
Are we aware of that and change this somewhere back to -O3? Otherwise Release might be a better default :)
More background in this thread: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/591
I realized the default build type for
CMakePackagein spack isbuild_type [RelWithDebInfo].That's cool (I do the same for my projects) because
-gcomes with no real (runtime) cost and adds understanding on crashes; but there is an important detail: due to legacy reasons, most compilers are set up with-O2on that build type:BLAST-WarpX/warpx#1201
BLAST-WarpX/warpx#1203
Are we aware of that and change this somewhere back to
-O3? OtherwiseReleasemight be a better default :)More background in this thread: https://gitlab.kitware.com/cmake/cmake/-/merge_requests/591