aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptedPythonInterface.h
diff options
context:
space:
mode:
authorNikita Popov <npopov@redhat.com>2022-06-16 12:13:37 +0200
committerNikita Popov <npopov@redhat.com>2022-06-17 15:01:41 +0200
commitc6b88cb9184fc6c17bb3d9c2c9568646dc46638d (patch)
tree87d55f9f9e261b9064c4b5049c98e4008dd50b34 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptedPythonInterface.h
parent7aac15d5df6cfa03b802e055b63227a95fa1734e (diff)
downloadllvm-c6b88cb9184fc6c17bb3d9c2c9568646dc46638d.zip
llvm-c6b88cb9184fc6c17bb3d9c2c9568646dc46638d.tar.gz
llvm-c6b88cb9184fc6c17bb3d9c2c9568646dc46638d.tar.bz2
[InstCombine] Push freeze through recurrence phi
We really want to push freezes through recurrence phis, so that we freeze only the start value, rather than the IV value on every iteration. foldOpIntoPhi() already handles this for the case where the transfer function doesn't produce poison, e.g. %iv.next = add %iv, 1. However, this does not work if nowrap flags are present, e.g. the very common %iv.next = add nuw %iv, 1 case. This patch adds a fold that pushes freeze instructions to the start value by checking whether all backedge values will be non-poison after poison generating flags have been dropped. This allows pushing freezes out of loops in most cases. I suspect that this also obsoletes the CanonicalizeFreezeInLoops pass, and we can probably drop it. Fixes https://github.com/llvm/llvm-project/issues/56048. Differential Revision: https://reviews.llvm.org/D127960
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptedPythonInterface.h')
0 files changed, 0 insertions, 0 deletions