aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp
diff options
context:
space:
mode:
authoreopXD <yueh.ting.chen@gmail.com>2022-09-19 19:07:43 -0700
committereopXD <yueh.ting.chen@gmail.com>2022-09-20 01:38:47 -0700
commit3b2011fd4f393c46ed1110840e0c00f52a582241 (patch)
treeb99be778d4f19251870ba53a3cf703ae5f32dbaf /lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp
parentb668de2de2c2216a744454dd5144b35a68698031 (diff)
downloadllvm-3b2011fd4f393c46ed1110840e0c00f52a582241.zip
llvm-3b2011fd4f393c46ed1110840e0c00f52a582241.tar.gz
llvm-3b2011fd4f393c46ed1110840e0c00f52a582241.tar.bz2
[LSR] Fold terminating condition to other IV when possible
When the IV is only used by the terminating condition (say IV-A) and the loop has a predictable back-edge count and we have another IV (say IV-B) that is an affine add recursion, we will be able to calculate the terminating value of IV-B in the loop pre-header. This patch adds attempts to replace IV-B as the new terminating condition and remove IV-A. It is safe to do so since IV-A is only used as the terminating condition. This transformation is suitable to be appended after LSR as it may optimize the loop into the situation mentioned above. The transformation can reduce number of IV-s in the loop by one. A cli option `lsr-term-fold` is added and default disabled. Reviewed By: mcberg2021, craig.topper Differential Revision: https://reviews.llvm.org/D132443
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationServerLLGS.cpp')
0 files changed, 0 insertions, 0 deletions