1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 03:02:36 +01:00

[VectorCombine] give invalid index value a name; NFC

This commit is contained in:
Sanjay Patel 2020-06-24 10:11:18 -04:00
parent 299253ac1c
commit 71738deebf

View File

@ -47,6 +47,8 @@ static cl::opt<bool> DisableBinopExtractShuffle(
"disable-binop-extract-shuffle", cl::init(false), cl::Hidden,
cl::desc("Disable binop extract to shuffle transforms"));
static const unsigned InvalidIndex = std::numeric_limits<unsigned>::max();
class VectorCombine {
public:
VectorCombine(Function &F, const TargetTransformInfo &TTI,
@ -293,7 +295,7 @@ bool VectorCombine::foldExtractExtract(Instruction &I) {
// probably becomes unnecessary.
auto *Ext0 = cast<ExtractElementInst>(I0);
auto *Ext1 = cast<ExtractElementInst>(I1);
uint64_t InsertIndex = std::numeric_limits<uint64_t>::max();
uint64_t InsertIndex = InvalidIndex;
if (I.hasOneUse())
match(I.user_back(),
m_InsertElt(m_Value(), m_Value(), m_ConstantInt(InsertIndex)));