summaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorAlex Bradbury <asb@lowrisc.org>2022-02-23 11:05:46 +0000
committerAlex Bradbury <asb@lowrisc.org>2022-02-23 11:05:46 +0000
commitc5bcfb983e47167a8a1826c1a64d7aa1849add06 (patch)
treeee2fef4a1d949961c378b0bc79c850a428571f02 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parentf84d732f8c1737940afab71824134f41f37a048b (diff)
[RISCV] Avoid infinite loop between DAGCombiner::visitMUL and RISCVISelLowering::transformAddImmMulImm
See https://github.com/llvm/llvm-project/issues/53831 for a full discussion. The basic issue is that DAGCombiner::visitMUL and RISCVISelLowering;:transformAddImmMullImm get stuck in a loop, as the current checks in transformAddImmMulImm aren't sufficient to avoid all cases where DAGCombiner::isMulAddWithConstProfitable might trigger a transformation. This patch makes transformAddImmMulImm bail out if C0 (the constant used for multiplication) has more than one use. Differential Revision: https://reviews.llvm.org/D120332
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions