[X86] Add a helper lambda to getIntelProcessorTypeAndSubtype to select feature bits...
authorCraig Topper <craig.topper@intel.com>
Fri, 12 Jun 2020 04:14:45 +0000 (21:14 -0700)
committerCraig Topper <craig.topper@intel.com>
Fri, 12 Jun 2020 04:14:46 +0000 (21:14 -0700)
commit0ce9bf6eed4a630f2b2735a7226c2d5bf2c7c57a
tree717d8860c07a1daa88616b614aa04c5e7ba749e5
parent999307323a456d5da958b4e2dd72874451487482
[X86] Add a helper lambda to getIntelProcessorTypeAndSubtype to select feature bits from the correct 32-bit feature variable.

We have three 32 bit variables containing feature bits. But our
enum is a flat 96 bit space. So we need to pick which of the
variables to use based on the bit value. We used to do this
manually by mentioning the correct variable and subtracting an
offset from the enum. But this is error prone.
llvm/lib/Support/Host.cpp