This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH, i386] Handle extended family cpuid info for AMD


On Thu, Jul 31, 2014 at 1:54 PM, Gopalasubramanian, Ganesh
<Ganesh.Gopalasubramanian@amd.com> wrote:
>> Then just use:
>
>> +      else if (has_avx2)
>> +        processor = PROCESSOR_BDVER4;
>>       else if (has_movbe)
>>        processor = PROCESSOR_BTVER2;
>>-      else if (has_avx2)
>>-        processor = PROCESSOR_BDVER4;
>>      else if (has_xsaveopt)
>
> In that case, with earlier GCC versions where we donât have bdver4 added, the fall back would be BTVER2,
> whereas a BD variant is more desirable.

I would like to have a check for a family at the beginning, something like:

      if (name == signature_NSC_ebx)
    processor = PROCESSOR_GEODE;
      else if (family == 22)
    {
      if (has_movbe)
        processor = PROCESSOR_BTVER2;
      else
        processor = PROCESSOR_BTVER1;
    }
      else if (has_avx2)
        processor = PROCESSOR_BDVER4;
      else if (has_xsaveopt)

Please also fix ChangeLog entry.

Uros.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]