Go to the documentation of this file.
23 #if (defined(__linux__) || defined(__ANDROID__)) && HAVE_GETAUXVAL && HAVE_ASM_HWCAP_H
25 #include <asm/hwcap.h>
28 #define get_cpu_feature_reg(reg, val) \
29 __asm__("mrs %0, " #reg : "=r" (val))
36 hwcap = getauxval(AT_HWCAP);
38 #if defined(HWCAP_CPUID)
47 if (hwcap & HWCAP_CPUID) {
50 get_cpu_feature_reg(ID_AA64ISAR0_EL1,
tmp);
51 if (((
tmp >> 44) & 0
xf) == 0x1)
53 get_cpu_feature_reg(ID_AA64ISAR1_EL1,
tmp);
54 if (((
tmp >> 52) & 0
xf) == 0x1)
64 #elif defined(__APPLE__) && HAVE_SYSCTLBYNAME
65 #include <sys/sysctl.h>
74 if (!sysctlbyname(
"hw.optional.arm.FEAT_DotProd", &
value, &
size,
NULL, 0)) {
79 if (!sysctlbyname(
"hw.optional.arm.FEAT_I8MM", &
value, &
size,
NULL, 0)) {
92 #ifdef PF_ARM_V82_DP_INSTRUCTIONS_AVAILABLE
93 if (IsProcessorFeaturePresent(PF_ARM_V82_DP_INSTRUCTIONS_AVAILABLE))
113 #ifdef __ARM_FEATURE_DOTPROD
116 #ifdef __ARM_FEATURE_MATMUL_INT8
#define AV_CPU_FLAG_DOTPROD
int av_get_cpu_flags(void)
Return the flags which specify extensions supported by the CPU.
size_t ff_get_cpu_max_align_aarch64(void)
int ff_get_cpu_flags_aarch64(void)
static int detect_flags(void)
#define xf(width, name, var, range_min, range_max, subs,...)
it s the only field you need to keep assuming you have a context There is some magic you don t need to care about around this just let it vf default value
#define AV_CPU_FLAG_ARMV8
#define flags(name, subs,...)