diff options
-rwxr-xr-x | configure.py | 15 | ||||
-rw-r--r-- | src/lib/utils/cpuid.cpp | 2 |
2 files changed, 8 insertions, 9 deletions
diff --git a/configure.py b/configure.py index ce829b666..e76ddf14c 100755 --- a/configure.py +++ b/configure.py @@ -657,21 +657,20 @@ class ModuleInfo(object): return ['HAS_' + d[0] + ' ' + d[1] for d in chunks(self.define, 2)] def compatible_cpu(self, archinfo, options): - arch_name = archinfo.basename cpu_name = options.cpu + for isa in self.need_isa: + if isa in options.disable_intrinsics: + return False # explicitly disabled + + if isa not in archinfo.isa_extensions: + return False + if self.arch != []: if arch_name not in self.arch and cpu_name not in self.arch: return False - for isa in self.need_isa: - if isa in options.disable_intrinsics: - return False # explicitly disabled - - if isa not in archinfo.isa_extensions: - return False - return True def compatible_os(self, os): diff --git a/src/lib/utils/cpuid.cpp b/src/lib/utils/cpuid.cpp index 6da5673c1..c49eb0752 100644 --- a/src/lib/utils/cpuid.cpp +++ b/src/lib/utils/cpuid.cpp @@ -183,7 +183,7 @@ void CPUID::initialize() { #if defined(BOTAN_TARGET_CPU_IS_PPC_FAMILY) if(altivec_check_sysctl() || altivec_check_pvr_emul()) - altivec_capable = true; + m_altivec_capable = true; #endif #if defined(BOTAN_TARGET_CPU_IS_X86_FAMILY) |