Skip to content

Commit a93ec74

Browse files
authored
Merge pull request #4948 from martin-frbg/fixhavesve
Properly report HAVE_SVE in ARM64 autodetection where applicable
2 parents 016bdb9 + c4bb4e7 commit a93ec74

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

cpuid_arm64.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -401,6 +401,7 @@ void get_cpuconfig(void)
401401
break;
402402

403403
case CPU_NEOVERSEV1:
404+
printf("#define HAVE_SVE 1\n");
404405
case CPU_CORTEXA76:
405406
printf("#define %s\n", cpuname[d]);
406407
printf("#define L1_CODE_SIZE 65536\n");
@@ -429,9 +430,11 @@ void get_cpuconfig(void)
429430
printf("#define L2_ASSOCIATIVE 8\n");
430431
printf("#define DTB_DEFAULT_ENTRIES 48\n");
431432
printf("#define DTB_SIZE 4096\n");
433+
printf("#define HAVE_SVE 1\n");
432434
break;
433435
case CPU_NEOVERSEV2:
434436
printf("#define ARMV9\n");
437+
printf("#define HAVE_SVE 1\n");
435438
printf("#define %s\n", cpuname[d]);
436439
printf("#define L1_CODE_SIZE 65536\n");
437440
printf("#define L1_CODE_LINESIZE 64\n");
@@ -452,6 +455,7 @@ void get_cpuconfig(void)
452455
case CPU_CORTEXX1:
453456
case CPU_CORTEXX2:
454457
printf("#define ARMV9\n");
458+
printf("#define HAVE_SVE 1\n");
455459
printf("#define %s\n", cpuname[d]);
456460
printf("#define L1_CODE_SIZE 65536\n");
457461
printf("#define L1_CODE_LINESIZE 64\n");
@@ -568,6 +572,7 @@ void get_cpuconfig(void)
568572
break;
569573
case CPU_A64FX:
570574
printf("#define A64FX\n");
575+
printf("#define HAVE_SVE 1\n");
571576
printf("#define L1_CODE_SIZE 65535\n");
572577
printf("#define L1_DATA_SIZE 65535\n");
573578
printf("#define L1_DATA_LINESIZE 256\n");

0 commit comments

Comments
 (0)