https://gcc.gnu.org/bugzilla/show_bug.cgi?id=70021
--- Comment #8 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
My patch (while IMHO needed) doesn't trigger on this testcase.
But, following untested hack:
--- tree-vect-stmts.c.jj3 2016-03-01 19:23:51.000000000 +0100
+++ tree-vect-stmts.c 2016-03-02 15:18:57.583005605 +0100
@@ -203,7 +203,7 @@ vect_mark_relevant (vec<gimple *> *workl
if (STMT_VINFO_IN_PATTERN_P (stmt_info))
{
bool found = false;
- if (!used_in_pattern)
+ if (false && !used_in_pattern)
{
imm_use_iterator imm_iter;
use_operand_p use_p;
fixes this testcase, and I really have hard time trying to understand what the
used_in_pattern stuff is about.
It has been introduced in
https://gcc.gnu.org/ml/gcc-patches/2011-06/msg02183.html
but I strongly hope we don't emit such stuff mentioned in the rationale anymore
(at least since the addition of pattern sequences), in particular a pattern
stmt that would have different behavior when used in some other pattern vs. in
normal stmt. Let me check the testsuite.