From e419620fc2f55cbc2decd468778376ec08d0190d Mon Sep 17 00:00:00 2001 From: Haohai Wen Date: Fri, 4 Nov 2022 10:15:11 +0800 Subject: [PATCH] [CodeGenPrep] Change ValueToSExts from DeseMap to MapVector mergeSExts iterates throught ValueToSExts. Using DenseMap result in unstable optimization path so that output IR may vary even if the input IR is same. Reviewed By: wxiao3 Differential Revision: https://reviews.llvm.org/D137234 --- llvm/lib/CodeGen/CodeGenPrepare.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/CodeGen/CodeGenPrepare.cpp b/llvm/lib/CodeGen/CodeGenPrepare.cpp index b9ffb8a8318f..cf2b32c74eb5 100644 --- a/llvm/lib/CodeGen/CodeGenPrepare.cpp +++ b/llvm/lib/CodeGen/CodeGenPrepare.cpp @@ -287,7 +287,7 @@ using SetOfInstrs = SmallPtrSet; using TypeIsSExt = PointerIntPair; using InstrToOrigTy = DenseMap; using SExts = SmallVector; -using ValueToSExts = DenseMap; +using ValueToSExts = MapVector; class TypePromotionTransaction;