Correct detection of NEON support (#392)
... as the test as it is currently implemented will always evaluate to true. Fixes #389
This commit is contained in:
parent
c9cd8e6211
commit
d33208c7db
|
@ -74,7 +74,7 @@ enum instruction_set {
|
|||
|
||||
#if defined(__arm__) || defined(__aarch64__) // incl. armel, armhf, arm64
|
||||
|
||||
#if defined(__NEON__)
|
||||
#if defined(__ARM_NEON)
|
||||
|
||||
static inline uint32_t detect_supported_architectures() {
|
||||
return instruction_set::NEON;
|
||||
|
|
|
@ -42,7 +42,7 @@ Architecture find_best_supported_implementation() {
|
|||
return Architecture::HASWELL;
|
||||
if ((westmere_flags & supports) == westmere_flags)
|
||||
return Architecture::WESTMERE;
|
||||
if (instruction_set::NEON)
|
||||
if (supports & instruction_set::NEON)
|
||||
return Architecture::ARM64;
|
||||
|
||||
return Architecture::NONE;
|
||||
|
|
|
@ -211,7 +211,7 @@ void find_the_best_supported_implementation() {
|
|||
}
|
||||
#endif
|
||||
#ifdef IS_ARM64
|
||||
if (instruction_set::NEON) {
|
||||
if (supports & instruction_set::NEON) {
|
||||
best_stage1 = simdjson::find_structural_bits<Architecture ::ARM64>;
|
||||
best_stage2 = simdjson::unified_machine<Architecture ::ARM64>;
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue