aarch64: Print the SVE vector length in libavutil/tests/cpu.c

This makes this aspect more visible in test logs.

Signed-off-by: Martin Storsjö <martin@martin.st>
This commit is contained in:
Martin Storsjö
2023-12-05 00:09:07 +02:00
parent e6eabb7ce7
commit b1ee2af843
4 changed files with 43 additions and 0 deletions
+8
View File
@@ -23,6 +23,10 @@
#include "libavutil/cpu.h"
#include "libavutil/avstring.h"
#if ARCH_AARCH64
#include "libavutil/aarch64/cpu.h"
#endif
#if HAVE_UNISTD_H
#include <unistd.h>
#endif
@@ -161,6 +165,10 @@ int main(int argc, char **argv)
print_cpu_flags(cpu_flags_raw, "raw");
print_cpu_flags(cpu_flags_eff, "effective");
printf("threads = %s (cpu_count = %d)\n", threads, cpu_count);
#if ARCH_AARCH64
if (cpu_flags_raw & AV_CPU_FLAG_SVE)
printf("sve_vector_length = %d\n", 8 * ff_aarch64_sve_length());
#endif
return 0;
}