diff --git a/llvm/utils/TableGen/FixedLenDecoderEmitter.cpp b/llvm/utils/TableGen/FixedLenDecoderEmitter.cpp --- a/llvm/utils/TableGen/FixedLenDecoderEmitter.cpp +++ b/llvm/utils/TableGen/FixedLenDecoderEmitter.cpp @@ -279,7 +279,7 @@ std::vector VariableInstructions; // Map of well-known segment value to its delegate. - std::map> FilterChooserMap; + std::map> FilterChooserMap; // Number of instructions which fall under FilteredInstructions category. unsigned NumFiltered; @@ -305,7 +305,7 @@ const FilterChooser &getVariableFC() const { assert(NumFiltered == 1); assert(FilterChooserMap.size() == 1); - return *(FilterChooserMap.find((unsigned)-1)->second); + return *(FilterChooserMap.find((uint64_t)-1)->second); } // Divides the decoding task into sub tasks and delegates them to the @@ -603,7 +603,7 @@ // Delegates to an inferior filter chooser for further processing on this // group of instructions whose segment values are variable. FilterChooserMap.insert( - std::make_pair(-1U, std::make_unique( + std::make_pair(-1ULL, std::make_unique( Owner->AllInstructions, VariableInstructions, Owner->Operands, BitValueArray, *Owner))); } @@ -674,7 +674,7 @@ for (auto &Filter : FilterChooserMap) { // Field value -1 implies a non-empty set of variable instructions. // See also recurse(). - if (Filter.first == (unsigned)-1) { + if (Filter.first == (uint64_t)-1) { HasFallthrough = true; // Each scope should always have at least one filter value to check