[Bug tree-optimization/64829] [ARM] ICE at -O3 in vect_get_vec_def_for_stmt_copy
ktkachov at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Jan 28 14:21:00 GMT 2015
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64829
--- Comment #7 from ktkachov at gcc dot gnu.org ---
>
> Index: gcc/tree-vect-patterns.c
> ===================================================================
> --- gcc/tree-vect-patterns.c (revision 220205)
> +++ gcc/tree-vect-patterns.c (working copy)
> @@ -1732,9 +1732,11 @@ vect_recog_widen_shift_pattern (vec<gimp
> if (TREE_CODE (oprnd0) != SSA_NAME || TREE_CODE (oprnd1) != INTEGER_CST)
> return NULL;
>
> - /* Check operand 0: it has to be defined by a type promotion. */
> - if (!type_conversion_p (oprnd0, last_stmt, false, &half_type0, &def_stmt0,
> - &promotion)
> + /* Check operand 0: it has to be defined by a type promotion and it
> + should be only used by the shift. */
> + if (!has_single_use (oprnd0)
> + || !type_conversion_p (oprnd0, last_stmt, false, &half_type0,
> &def_stmt0,
> + &promotion)
> || !promotion)
> return NULL;
That fixes the ICE in the testcase for me.
I'll give it a test on arm-none-eabi and an arm bootstrap
More information about the Gcc-bugs
mailing list