[PATCH] D158291: [PoC][WIP] Add an AArch64 specific pass for loop idiom recognition
David Sherwood via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 14 06:01:53 PST 2023
david-arm marked 7 inline comments as done.
david-arm added inline comments.
================
Comment at: llvm/lib/Target/AArch64/AArch64LoopIdiomRecognize.cpp:159
+bool AArch64LoopIdiomRecognize::run(Loop *L) {
+ CurLoop = L;
+
----------------
craig.topper wrote:
> craig.topper wrote:
> > Do we need to check `skipLoop` for opt-bisect-limit?
> Maybe skipLoop is handled directly by the new pass manager? I'm too used to old pass manager.
For the legacy pass manager we do!
================
Comment at: llvm/lib/Target/AArch64/AArch64LoopIdiomRecognize.cpp:206
+ auto *EntryBI = dyn_cast<BranchInst>(PH->getTerminator());
+ if (!EntryBI || EntryBI->isConditional())
+ return false;
----------------
craig.topper wrote:
> Doesn't being a "preheader" guarantee it's not conditional?
You're right. I've simplified the logic here to assume a canonical form, particularly since we rejected loops without preheaders in AArch64LoopIdiomRecognize::run
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D158291/new/
https://reviews.llvm.org/D158291
More information about the llvm-commits
mailing list