aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-strings/llvm-strings.cpp
diff options
context:
space:
mode:
authorMatthias Springer <springerm@google.com>2022-12-23 13:01:00 +0100
committerMatthias Springer <springerm@google.com>2022-12-23 13:08:53 +0100
commit391cb541223bb0d41620eb5e25c107563dc3e12c (patch)
tree06ac5d45388aac79bd681a616bd6e6c263242662 /llvm/tools/llvm-strings/llvm-strings.cpp
parent4861a58769e882fc9fef2ec55429a639deb0aa42 (diff)
downloadllvm-391cb541223bb0d41620eb5e25c107563dc3e12c.zip
llvm-391cb541223bb0d41620eb5e25c107563dc3e12c.tar.gz
llvm-391cb541223bb0d41620eb5e25c107563dc3e12c.tar.bz2
[mlir] Add option to limit number of pattern rewrites in CanonicalizerPass
The greedy pattern rewriter consists of two nested loops. `config.maxIterations` (which configurable on the CanonicalizerPass) controls the maximum number of iterations of the outer loop. ``` /// This specifies the maximum number of times the rewriter will iterate /// between applying patterns and simplifying regions. Use `kNoLimit` to /// disable this iteration limit. int64_t maxIterations = 10; ``` This change adds `config.maxNumRewrites` which controls the maximum number of pattern rewrites within an iteration. (It effectively control the maximum number of iterations of the inner loop.) This flag is meant for debugging and useful in cases where one or multiple faulty patterns can be applied indefinitely, resulting in an infinite loop. Differential Revision: https://reviews.llvm.org/D140525
Diffstat (limited to 'llvm/tools/llvm-strings/llvm-strings.cpp')
0 files changed, 0 insertions, 0 deletions