[llvm] e419620 - [CodeGenPrep] Change ValueToSExts from DeseMap to MapVector
Haohai Wen via llvm-commits
llvm-commits at lists.llvm.org
Thu Nov 3 20:15:42 PDT 2022
Author: Haohai Wen
Date: 2022-11-04T11:15:18+08:00
New Revision: e419620fc2f55cbc2decd468778376ec08d0190d
URL: https://github.com/llvm/llvm-project/commit/e419620fc2f55cbc2decd468778376ec08d0190d
DIFF: https://github.com/llvm/llvm-project/commit/e419620fc2f55cbc2decd468778376ec08d0190d.diff
LOG: [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
Added:
Modified:
llvm/lib/CodeGen/CodeGenPrepare.cpp
Removed:
################################################################################
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<Instruction *, 16>;
using TypeIsSExt = PointerIntPair<Type *, 2, ExtType>;
using InstrToOrigTy = DenseMap<Instruction *, TypeIsSExt>;
using SExts = SmallVector<Instruction *, 16>;
-using ValueToSExts = DenseMap<Value *, SExts>;
+using ValueToSExts = MapVector<Value *, SExts>;
class TypePromotionTransaction;
More information about the llvm-commits
mailing list