New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
setAlreadyVectorized does not delete obsolete metadata #21029
Comments
assigned to @rengolin |
Right, seems an vectorizer vs. O3+vectorizer issue, as with just -O3 the loop looks perfect. Still, I think we could make setAlreadyVectorized() clean up after itself without needing additional cleanup passes. I'll have a look, should be simple. |
Ended up refactoring the whole hint code... :) |
Fixed in r215994 |
MSVC 2011 can't cope with my patch's C++11 goodness, so this will have to wait. Once MSVC 2013 becomes the new minimum requirement, I'll commit again. |
Is there a reason why a work-around would be difficult? |
No reason, but the bug is very low priority, since it only happens in a particularly obscure combination of flags and even so, it's not really that critical. I'd rather wait for a nice code than work around it now and forget later. :) If this really affects people's work I can think of a work around, of course. |
Trying again on r216870 with MSVC2012-safe code. |
It seems MSVC 2012 is happy with the code, thanks Seth Cantrell for the tip. |
Extended Description
When pass loop-vectorize runs, it adds new loop metadata to indicate that the vectorizer ran, but fails to remove the old conflicting metadata. For example, if you take the attached file for.ll and process it with:
the output has:
Note that !3 contains two conflicting widths: a width of 1 inside !2 and a width of 4 inside !4. The pass should not have included !4 inside !3.
I'm using LLVM version 3.6.0svn.
The text was updated successfully, but these errors were encountered: