[PATCH] D111125: [NFC][LoopVectorize] Remove setBestPlan in favour of getBestPlanFor

David Sherwood via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 6 00:52:18 PDT 2021


david-arm added a comment.

In D111125#3043297 <https://reviews.llvm.org/D111125#3043297>, @bmahjour wrote:

> Seems like a reasonable idea to me, but just pointing out that the lifetime of unused plans will be extended with this patch. Could we delete unused plans, eg by calling something like `LVP.deleteVPlansExcept(BestPlan2)` right before `LVP.executePlan(...,)` on line 10435?

Hi @bmahjour, I think that's basically what I was doing in D109432 <https://reviews.llvm.org/D109432>, where I backed up a copy of the plans before deleting them. @sdesmalen suggested I could take a different approach with this patch instead. The problem is that once the plans are deleted I can't get them back again, and the scalable VFs and fixed-width VFs live in different plans. This meant that if I deleted the plans when emitting the main vector loop, I then had to find a way of reinstating the plans so I could then generate the epilogue vector loop.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D111125/new/

https://reviews.llvm.org/D111125



More information about the llvm-commits mailing list