[PATCH] D29404: [ValueTracking] emit a warning when we detect a conflicting assumption (PR31809)

Adam Nemet via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 2 10:38:03 PST 2017

anemet requested changes to this revision.
anemet added a comment.
This revision now requires changes to proceed.

In https://reviews.llvm.org/D29404#664884, @spatel wrote:

> But this isn't behaving the way I expected: shouldn't this show up as a "warning" rather than a "remark" and without needing to specify "-pass-remarks-missed=.*"? Ie, DS_Warning was specified in the creation of the underlying DiagnosticInfoIROptimization().

Yes, it should:

$ ./bin/opt -loop-vectorize ../test/Transforms/LoopVectorize/X86/vectorization-remarks-missed.ll -o /dev/null
remark: source.cpp:19:5: loop not vectorized: cannot identify array bounds
warning: source.cpp:19:5: loop not vectorized: failed explicitly specified loop vectorization

The remark part is special-cased in LV to always appear  but I think the warning is supposed to show up regardless.

Also once you resolve this part, you still need to change the patch to use ORE as an analysis pass via InstSimplify.


More information about the llvm-commits mailing list