aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/LiveDebugVariables.cpp
diff options
context:
space:
mode:
authorDawid Jurczak <dawid_jurek@vp.pl>2021-08-25 13:13:18 +0200
committerDawid Jurczak <dawid_jurek@vp.pl>2021-08-25 14:22:40 +0200
commitbdcf04246c401aec9bdddf32fabc99fa4834a477 (patch)
tree5e76b6b71c513d4cabfdc46707ae08eedab985c6 /llvm/lib/CodeGen/LiveDebugVariables.cpp
parente708808f875f58344ecaad66d9e6e167ca7ac90a (diff)
downloadllvm-bdcf04246c401aec9bdddf32fabc99fa4834a477.zip
llvm-bdcf04246c401aec9bdddf32fabc99fa4834a477.tar.gz
llvm-bdcf04246c401aec9bdddf32fabc99fa4834a477.tar.bz2
[LoopIdiom] Don't transform loop into memmove when load from body has more than one use
This change fixes issue found by Markus: https://reviews.llvm.org/rG11338e998df1 Before this patch following code was transformed to memmove: for (int i = 15; i >= 1; i--) { p[i] = p[i-1]; sum += p[i-1]; } However load from p[i-1] is used not only by store to p[i] but also by sum computation. Therefore we cannot emit memmove in loop header. Differential Revision: https://reviews.llvm.org/D107964
Diffstat (limited to 'llvm/lib/CodeGen/LiveDebugVariables.cpp')
0 files changed, 0 insertions, 0 deletions