aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineScheduler.cpp
diff options
context:
space:
mode:
authorMax Kazantsev <max.kazantsev@azul.com>2017-06-21 07:28:13 +0000
committerMax Kazantsev <max.kazantsev@azul.com>2017-06-21 07:28:13 +0000
commiteac01d4c625ca91ec66e08b979e9c4a2b7f5dc5c (patch)
treedc28c7619cf770deb7ad39bdc2704352233b03c2 /llvm/lib/CodeGen/MachineScheduler.cpp
parent2c8e3ed00fb94e484c0edad9045641c4659a30d3 (diff)
downloadllvm-eac01d4c625ca91ec66e08b979e9c4a2b7f5dc5c.zip
llvm-eac01d4c625ca91ec66e08b979e9c4a2b7f5dc5c.tar.gz
llvm-eac01d4c625ca91ec66e08b979e9c4a2b7f5dc5c.tar.bz2
[SCEV] Make MulOpsInlineThreshold lower to avoid excessive compilation time
MulOpsInlineThreshold option of SCEV is defaulted to 1000, which is inadequately high. When constructing SCEVs of expressions like: x1 = a * a x2 = x1 * x1 x3 = x2 * x2 ... We actually have huge SCEVs with max allowed amount of operands inlined. Such expressions are easy to get from unrolling of loops looking like x = a for (i = 0; i < n; i++) x = x * x Or more tricky cases where big powers are involved. If some non-linear analysis tries to work with a SCEV that has 1000 operands, it may lead to excessively long compilation. The attached test does not pass within 1 minute with default threshold. This patch decreases its default value to 32, which looks much more reasonable if we use analyzes with complexity O(N^2) or O(N^3) working with SCEV. Differential Revision: https://reviews.llvm.org/D34397 llvm-svn: 305882
Diffstat (limited to 'llvm/lib/CodeGen/MachineScheduler.cpp')
0 files changed, 0 insertions, 0 deletions