https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86097

--- Comment #5 from rguenther at suse dot de <rguenther at suse dot de> ---
On Wed, 20 Jun 2018, vries at gcc dot gnu.org wrote:

> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86097
> 
> --- Comment #3 from Tom de Vries <vries at gcc dot gnu.org> ---
> Tentative patch:
> ...
> diff --git a/gcc/tree-ssa-loop-manip.c b/gcc/tree-ssa-loop-manip.c
> index bf425afd436..555842b8420 100644
> --- a/gcc/tree-ssa-loop-manip.c
> +++ b/gcc/tree-ssa-loop-manip.c
> @@ -1542,7 +1542,7 @@ canonicalize_loop_ivs (struct loop *loop, tree *nit, 
> bool
> bump_in_latc
> h)
>    precision = GET_MODE_PRECISION (mode);
>    type = build_nonstandard_integer_type (precision, unsigned_p);
> 
> -  if (original_precision != precision)
> +  if (original_precision != precision || type != TREE_TYPE (*nit))

|| TYPE_UNSIGNED (*nit) != unsigned_p

Reply via email to