[all-commits] [llvm/llvm-project] 026170: Fix range-loop-analysis warning
Keith Smiley via All-commits
all-commits at lists.llvm.org
Thu Jun 10 08:49:45 PDT 2021
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 026170d17d1eb8956237ba88c07a60f07445ebf1
https://github.com/llvm/llvm-project/commit/026170d17d1eb8956237ba88c07a60f07445ebf1
Author: Keith Smiley <keithbsmiley at gmail.com>
Date: 2021-06-10 (Thu, 10 Jun 2021)
Changed paths:
M llvm/lib/Transforms/Vectorize/LoopVectorize.cpp
Log Message:
-----------
Fix range-loop-analysis warning
```
llvm-project/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:8024:19: warning: loop variable 'VF' of type 'const llvm::ElementCount' creates a copy from type 'const llvm::ElementCount' [-Wrange-loop-analysis]
for (const auto VF : VFCandidates) {
^
llvm-project/llvm/lib/Transforms/Vectorize/LoopVectorize.cpp:8024:8: note: use reference type 'const llvm::ElementCount &' to prevent copying
for (const auto VF : VFCandidates) {
^~~~~~~~~~~~~~~
&
1 warning generated.
```
Differential Revision: https://reviews.llvm.org/D103970
More information about the All-commits
mailing list