[TableGen,GlobalISel] Use MapVector to stabilize iteration order
Otherwise llvm/test/TableGen/GlobalISelCombinerEmitter/type-inference.td could fail when llvm::hash_value(StringRef) changes. Fix #66377
This commit is contained in:
@@ -529,7 +529,7 @@ void CombineRuleOperandTypeChecker::getInstEqClasses(
|
||||
const auto MCOITypes = getMCOIOperandTypes(*CGP);
|
||||
assert(MCOITypes.size() == P.operands_size());
|
||||
|
||||
DenseMap<StringRef, std::vector<unsigned>> TyToOpIdx;
|
||||
MapVector<StringRef, SmallVector<unsigned, 0>> TyToOpIdx;
|
||||
for (const auto &[Idx, Ty] : enumerate(MCOITypes))
|
||||
TyToOpIdx[Ty].push_back(Idx);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user