------- Comment #7 from changpeng dot fang at amd dot com 2010-08-10 21:44 ------- (In reply to comment #5) > (In reply to comment #1) > > This patch should be a valid fix, because the recognition of the dot_prod > > pattern is known to be fail at this point if the stmt is outside the loop. > > (I am not sure whether we should not see this case in the vectorizer at this > > point -- should previous analysis already filter out?): > > > > I don't understand this. Where do we check if the stmt (which one?) is outside > the loop?
Forget about this part of the comment (The vectorization analysis is correct, and it is just that the pattern recognition traces the chain outside the loop). > I was looking at PR 45239 and didn't notice that there is another PR and > didn't > see this comment. So I tested the same fix (successfully on > x86_64-suse-linux). > You can commit it if you like (just please notice, that the bug exists on 4.5 > as well). > I am going to add your testcase (in comment #4), and doing bootstraping, and then commit to the trunk and gcc 4.5 branch. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45241