aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/MachineOperand.cpp
diff options
context:
space:
mode:
authorPeilin Guo <guopeilin1@huawei.com>2021-05-07 16:05:50 +0800
committerPeilin Guo <guopeilin1@huawei.com>2021-05-07 16:05:50 +0800
commit911a541620bcc78e637589b8623d94b8f3cdafba (patch)
tree38746ccd83db5c58f51380f475c01e3f0190ff17 /llvm/lib/CodeGen/MachineOperand.cpp
parent9deb7eeaf76c3285b72ce75d30fcade63b96e2dc (diff)
downloadllvm-911a541620bcc78e637589b8623d94b8f3cdafba.zip
llvm-911a541620bcc78e637589b8623d94b8f3cdafba.tar.gz
llvm-911a541620bcc78e637589b8623d94b8f3cdafba.tar.bz2
[LazyValueInfo] Insert an Overdefined placeholder to prevent infinite recursion
getValueFromCondition() uses a Visited set to record the intermediate value. However, it uses a postorder way to compute the value first and update the Visited set later. Thus it will be trapped into an infinite recursion if there exists IRs that use no dominated by its def as in this example: %tmp3 = or i1 undef, %tmp4 %tmp4 = or i1 undef, %tmp3 To prevent this, we can insert an Overdefined placeholder into the set before computing the actual value. Reviewed by: nikic Differential Revision: https://reviews.llvm.org/D101273
Diffstat (limited to 'llvm/lib/CodeGen/MachineOperand.cpp')
0 files changed, 0 insertions, 0 deletions