llvm-project/mlir/lib/Transforms
Chris Lattner 40a89da65c [Canonicalize] Don't call isBeforeInBlock in OperationFolder::tryToFold.
This patch (e4635e6328) fixed a bug where a newly generated/reused
constant wouldn't dominate a folded operation.  It did so by calling
isBeforeInBlock to move the constant around on demand.  This introduced
a significant compile time regression, because "isBeforeInBlock" is
O(n) in the size of a block the first time it is called, and the cache
is invalidated any time canonicalize changes something big in the block.

This fixes LLVM PR51738 and this CIRCT issue:
https://github.com/llvm/circt/issues/1700

This does affect the order of constants left in the top of a block,
I staged in the testsuite changes in rG42431b8207a5.

Differential Revision: https://reviews.llvm.org/D109454
2021-09-08 13:33:22 -07:00
..
Utils [Canonicalize] Don't call isBeforeInBlock in OperationFolder::tryToFold. 2021-09-08 13:33:22 -07:00
BufferDeallocation.cpp [mlir] split type conversion to two lines for GCC's sake 2021-07-26 14:15:47 +02:00
BufferOptimizations.cpp [mlir] Added new RegionBranchTerminatorOpInterface and adapted uses of hasTrait<ReturnLike>. 2021-07-26 06:39:31 +02:00
BufferResultsToOutParams.cpp [MLIR] Create memref dialect and move dialect-specific ops from std. 2021-03-15 11:14:09 +01:00
BufferUtils.cpp [MLIR][memref] Fix findDealloc() to handle > 1 dealloc for the given alloc. 2021-07-22 09:34:19 -07:00
Bufferize.cpp [PatternMatch] Big mechanical rename OwningRewritePatternList -> RewritePatternSet and insert -> add. NFC 2021-03-22 17:20:50 -07:00
CMakeLists.txt [mlir] Support drawing control-flow graphs in ViewOpGraph.cpp 2021-08-04 20:45:15 +09:00
CSE.cpp Implement recursive support into OperationEquivalence::isEquivalentTo() 2021-07-29 05:06:37 +00:00
Canonicalizer.cpp [mlir] Add support for filtering patterns based on debug names and labels 2021-06-02 12:05:25 -07:00
Inliner.cpp [mlir] Add a ThreadPool to MLIRContext and refactor MLIR threading usage 2021-06-23 01:29:24 +00:00
LocationSnapshot.cpp [mlir] Added OpPrintingFlags to AsmState and SSANameState. 2021-07-10 16:40:00 +00:00
LoopCoalescing.cpp [MLIR] Add loop coalesce utility for affine.for 2021-09-08 18:02:23 +05:30
LoopFusion.cpp [mlir][Analysis][NFC] Clean up FlatAffineValueConstraints 2021-08-17 10:38:57 +09:00
LoopInvariantCodeMotion.cpp [mlir][BuiltinDialect] Resolve comments from D91571 2020-11-19 11:12:49 -08:00
NormalizeMemRefs.cpp [Builder] Eliminate the StringRef/StringAttr forms of getSymbolRefAttr. 2021-08-30 16:05:36 -07:00
OpStats.cpp [mlir][BuiltinDialect] Resolve comments from D91571 2020-11-19 11:12:49 -08:00
ParallelLoopCollapsing.cpp [mlir] NFC: Rename LoopOps dialect to SCF (Structured Control Flow) 2020-05-11 15:04:27 +02:00
PassDetail.h [mlir] Normalize dynamic memrefs with a map of tiled-layout. 2021-05-24 08:39:36 +05:30
PipelineDataTransfer.cpp [mlir][NFC] MemRef cleanup: Remove helper functions 2021-07-05 10:10:21 +09:00
SCCP.cpp [mlir] Refactor the forward dataflow propagation in SCCP into a generic framework 2021-04-26 19:39:46 -07:00
StripDebugInfo.cpp [mlir] Make StripDebugInfo strip out block arguments locs 2021-05-26 11:05:38 -07:00
SymbolDCE.cpp Define a `NoTerminator` traits that allows operations with a single block region to not provide a terminator 2021-03-25 03:59:03 +00:00
ViewOpGraph.cpp [mlir] Cleanup: Fix warnings in MLIR 2021-08-06 10:36:37 +09:00