[PATCH] D42312: [ARM] Cleanup part of ARMBaseInstrInfo::optimizeCompareInstr (NFCI).

Joel Galenson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Jan 19 12:40:31 PST 2018


jgalenson added a comment.

I considered using reverse_iterator here, but I couldn't get something that looked clean to me, since I had to convert I and E and compare against E and the beginning of the block.  I also considered splitting this loop into two, one that searches for SubAdd and one that checks for CPSR reads/writes, but that also seemed more complicated.  I'd be open to suggestions on how to improve this further, though.


https://reviews.llvm.org/D42312





More information about the llvm-commits mailing list