diff --git a/var/spack/repos/builtin/packages/fftw/package.py b/var/spack/repos/builtin/packages/fftw/package.py index f6a5e83908..a4ba9ae20c 100644 --- a/var/spack/repos/builtin/packages/fftw/package.py +++ b/var/spack/repos/builtin/packages/fftw/package.py @@ -111,9 +111,14 @@ def configure(self, spec, prefix): # float only float_simd_features = ['altivec', 'sse'] - # Workaround NVIDIA compiler bug when avx512 is enabled - if spec.satisfies('%nvhpc') and 'avx512' in simd_features: - simd_features.remove('avx512') + # Workaround PGI compiler bug when avx2 is enabled + if spec.satisfies('%pgi') and 'avx2' in simd_features: + simd_features.remove('avx2') + + # Workaround NVIDIA/PGI compiler bug when avx512 is enabled + if spec.satisfies('%nvhpc') or spec.satisfies('%pgi'): + if 'avx512' in simd_features: + simd_features.remove('avx512') # NVIDIA compiler does not support Altivec intrinsics if spec.satisfies('%nvhpc') and 'vsx' in simd_features: