Spack will consider all the microarchitectures known to archspec to label nodes for compatibility. If instead the option is set to:
concretizer:
targets:
granularity: generic
Spack will consider only generic microarchitectures. For instance, when running on an Haswell node, Spack will consider haswell as the best target in the former case and x86_64_v3 as the best target in the latter case.
With granularity set to generic, we get:
export SPACK_TARGET_ARGS='-march=pentium4 -mtune=generic';
With granularity set to microarchitectures, we get:
export SPACK_TARGET_ARGS='-march=cascadelake -mtune=cascadelake';
https://spack.readthedocs.io/en/latest/build_settings.html#concretizer-options :
With
granularity
set togeneric
, we get:export SPACK_TARGET_ARGS='-march=pentium4 -mtune=generic';
With
granularity
set tomicroarchitectures
, we get:export SPACK_TARGET_ARGS='-march=cascadelake -mtune=cascadelake';
Configuration: