From 847429304e898221c3b239a5625d0010cc5a5dc9 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Wed, 20 Nov 2024 14:46:45 -0800 Subject: [PATCH] Check that AltiVec is enabled before using it --- common/pffft.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common/pffft.cpp b/common/pffft.cpp index fb26b847a7..36e965428a 100644 --- a/common/pffft.cpp +++ b/common/pffft.cpp @@ -98,7 +98,8 @@ namespace { /* * Altivec support macros */ -#if defined(__ppc__) || defined(__ppc64__) || defined(__powerpc__) || defined(__powerpc64__) +#if (defined(__ppc__) || defined(__ppc64__) || defined(__powerpc__) || defined(__powerpc64__)) \ + && (defined(__VEC__) || defined(__ALTIVEC__)) #include using v4sf = vector float; constexpr uint SimdSize{4};