Skip to content

Commit cdcdb78

Browse files
committed
CPU (Windows): refines ARMv8.4-A detection to require LSE2
1 parent 2ae9d01 commit cdcdb78

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/detection/cpu/cpu.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,7 @@ void ffCPUDetectByCpuid(FFCPUResult* cpu)
429429

430430
// ARMv8.4-A
431431
// My CPU (Apple M1 Pro in VM) does support LSE2, but Windows doesn't detect it for some reason
432-
// bool has_lse2 = IsProcessorFeaturePresent(PF_ARM_LSE2_AVAILABLE); // Large System Extensions version 2, optional from v8.2
432+
bool has_lse2 = IsProcessorFeaturePresent(PF_ARM_LSE2_AVAILABLE); // Large System Extensions version 2, optional from v8.2
433433
bool has_dp = IsProcessorFeaturePresent(PF_ARM_V82_DP_INSTRUCTIONS_AVAILABLE); // DotProd, optional from v8.1 (*)
434434

435435
// ARMv9.0-A
@@ -475,7 +475,7 @@ void ffCPUDetectByCpuid(FFCPUResult* cpu)
475475
cpu->march = "ARMv8.7-A";
476476
} else if (has_i8mm && has_bf16) {
477477
cpu->march = "ARMv8.6-A";
478-
} else if (has_dp) {
478+
} else if (has_dp && has_lse2) {
479479
cpu->march = "ARMv8.4-A";
480480
} else if (has_lrcpc && has_jscvt) {
481481
cpu->march = "ARMv8.3-A";

0 commit comments

Comments
 (0)