[llvm] [LoopVectorize] Add support for vectorisation of more early exit loops (PR #88385)

Graham Hunter via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 13 02:21:18 PDT 2024


================
@@ -404,6 +424,22 @@ class LoopVectorizationLegality {
 
   DominatorTree *getDominatorTree() const { return DT; }
 
+  /// Returns all exiting blocks with a countable exit, i.e. the
+  /// exit-not-taken count is known exactly at compile time.
+  const SmallVector<BasicBlock *, 4> &getCountableExitingBlocks() const {
----------------
huntergr-arm wrote:

I think it would be better to use `SmallVectorImpl<BasicBlock *>` instead of tying the result type to the default parameter.

https://github.com/llvm/llvm-project/pull/88385


More information about the llvm-commits mailing list