[FFmpeg-devel] [PATCH] Add AVX2 capable CPU detection

Reimar Döffinger Reimar.Doeffinger at gmx.de
Sun Oct 20 17:21:03 CEST 2013


On 20.10.2013, at 16:46, Kieran Kunhya <kierank at ob-encoder.com> wrote:
> diff --git a/libavutil/x86/cpu.c b/libavutil/x86/cpu.c
> index 3e946b8..07a8425 100644
> --- a/libavutil/x86/cpu.c
> +++ b/libavutil/x86/cpu.c
> @@ -134,6 +134,15 @@ int ff_get_cpu_flags_x86(void)
>             if ((eax & 0x6) == 0x6)
>                 rval |= AV_CPU_FLAG_AVX;
>         }
> +#if HAVE_AVX2
> +    if( max_std_level >= 7 )

Why not
if (HAVE_AVX2 && ...
instead of the #if ?


More information about the ffmpeg-devel mailing list