[x265] [PATCH] remove 'bool bEnableavx512' from x265.h

Pradeep Ramachandran pradeep at multicorewareinc.com
Wed May 2 09:43:33 CEST 2018


On Wed, May 2, 2018 at 9:42 AM, Jayashree Chandrasekaran <
jayashree.c at multicorewareinc.com> wrote:

> Hi
>
> I thought having a variable gives better clarity and that the variable can
> be used in future if needed.
> Thanks for the patch. It also fixes the ffmpeg crash issue reported with
> the previous commit.
>
>
>
> On Wed, May 2, 2018 at 12:50 AM, Ma0 <mateuszb at poczta.onet.pl> wrote:
>
>> # HG changeset patch
>> # User Ma0 <mateuszb at poczta.onet.pl>
>> # Date 1525200622 -7200
>> #      Tue May 01 20:50:22 2018 +0200
>> # Branch stable
>> # Node ID 756a85b9b2db75aef1e1a81745769a24c0cdbbe6
>> # Parent  091f07265371ae6ee2c38795d5554e6146acc18b
>> remove 'bool bEnableavx512' from x265.h
>>
>> bEnableavx512 is/should be copy of 16th bit in cpuid so it is
>> redundant
>>
>
Pushed to stable. Thanks for the patch.


>
>> diff -r 091f07265371 -r 756a85b9b2db source/CMakeLists.txt
>> --- a/source/CMakeLists.txt     Tue Apr 24 10:37:02 2018 +0530
>> +++ b/source/CMakeLists.txt     Tue May 01 20:50:22 2018 +0200
>> @@ -29,7 +29,7 @@
>>  option(STATIC_LINK_CRT "Statically link C runtime for release builds"
>> OFF)
>>  mark_as_advanced(FPROFILE_USE FPROFILE_GENERATE NATIVE_BUILD)
>>  # X265_BUILD must be incremented each time the public API is changed
>> -set(X265_BUILD 159)
>> +set(X265_BUILD 160)
>>  configure_file("${PROJECT_SOURCE_DIR}/x265.def.in"
>>                 "${PROJECT_BINARY_DIR}/x265.def")
>>  configure_file("${PROJECT_SOURCE_DIR}/x265_config.h.in"
>> diff -r 091f07265371 -r 756a85b9b2db source/common/param.cpp
>> --- a/source/common/param.cpp   Tue Apr 24 10:37:02 2018 +0530
>> +++ b/source/common/param.cpp   Tue May 01 20:50:22 2018 +0200
>> @@ -618,20 +618,16 @@
>>  #if X265_ARCH_X86
>>          if (!strcasecmp(value, "avx512"))
>>          {
>> -            p->bEnableavx512 = true;
>> -
>> -            p->cpuid = X265_NS::cpu_detect(p->bEnableavx512);
>> +            p->cpuid = X265_NS::cpu_detect(true);
>>              if (!(p->cpuid & X265_CPU_AVX512))
>>                  x265_log(p, X265_LOG_WARNING, "AVX512 is not
>> supported\n");
>>          }
>>          else
>>          {
>> -            p->bEnableavx512 = false;
>> -
>>              if (bValueWasNull)
>>                  p->cpuid = atobool(value);
>>              else
>> -                p->cpuid = parseCpuName(value, bError, p->bEnableavx512);
>> +                p->cpuid = parseCpuName(value, bError, false);
>>          }
>>  #else
>>          if (bValueWasNull)
>> diff -r 091f07265371 -r 756a85b9b2db source/x265.h
>> --- a/source/x265.h     Tue Apr 24 10:37:02 2018 +0530
>> +++ b/source/x265.h     Tue May 01 20:50:22 2018 +0200
>> @@ -629,14 +629,6 @@
>>       * somehow flawed on your target hardware. The asm function tables
>> are
>>       * process global, the first encoder configures them for all
>> encoders */
>>      int       cpuid;
>> -     /*==Assembly features ==*/
>> -     /*  x265_param_parse() will detect if the avx512 is enabled (in cli
>> )and set
>> -     *  bEnableavx512 to 1 to use avx512 SIMD. By default this flag will
>> not be set ,
>> -     *  hence the encoding will happen without avx512 assembly
>> primitives even if the cpu has
>> -     *  avx512 capabilities.
>> -     *  Ensure to use --asm avx512 if you need to encode with avx512
>> assembly primitives*/
>> -
>> -    bool  bEnableavx512;
>>      /*== Parallelism Features ==*/
>>
>>      /* Number of concurrently encoded frames between 1 and
>> X265_MAX_FRAME_THREADS
>> _______________________________________________
>> x265-devel mailing list
>> x265-devel at videolan.org
>> https://mailman.videolan.org/listinfo/x265-devel
>>
>
>
> _______________________________________________
> x265-devel mailing list
> x265-devel at videolan.org
> https://mailman.videolan.org/listinfo/x265-devel
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/x265-devel/attachments/20180502/0e851b2d/attachment-0001.html>


More information about the x265-devel mailing list