[PATCH] D91857: [ARM] Remove dead mov's in preheader of tail predicated loops
Dave Green via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 20 06:52:36 PST 2020
dmgreen added inline comments.
================
Comment at: llvm/lib/Target/ARM/ARMLowOverheadLoops.cpp:793
+ // If we converted the LoopStart to a t2DoLoopStartTP, we can also remove any
+ // extra instructions in the preheader, which often includes a now unused MOV.
+ if (Start->getOpcode() == ARM::t2DoLoopStartTP && Preheader &&
----------------
samtebbs wrote:
> Is it guaranteed that these extra instructions are unused (and so it's ok to remove them without any extra RDA checks)?
I am hoping that is what TryRemove will do. It checks for things like corrupting IT blocks too.
I'm not super confident about this code late-backend dead code removal not causing some problems, but hope it's at least as sane as the existing checks. I have not seen any problems so far at least.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D91857/new/
https://reviews.llvm.org/D91857
More information about the llvm-commits
mailing list