This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/78742] [5/6/7 Regression] internal compiler error: in int_cst_value, at tree.c:10782
- From: "rguenther at suse dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 09 Dec 2016 10:27:12 +0000
- Subject: [Bug tree-optimization/78742] [5/6/7 Regression] internal compiler error: in int_cst_value, at tree.c:10782
- Auto-submitted: auto-generated
- References: <bug-78742-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78742
--- Comment #6 from rguenther at suse dot de <rguenther at suse dot de> ---
On Fri, 9 Dec 2016, mpolacek at gcc dot gnu.org wrote:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78742
>
> --- Comment #5 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
> FWIW, my untested fix was
>
> --- a/gcc/tree-data-ref.c
> +++ b/gcc/tree-data-ref.c
> @@ -2781,6 +2781,10 @@ can_use_analyze_subscript_affine_affine (tree *chrec_a,
> tree *chrec_b)
> /* FIXME: For the moment not handled. Might be refined later. */
> return false;
>
> + if (!cst_and_fits_in_hwi (CHREC_RIGHT (*chrec_a))
> + || !cst_and_fits_in_hwi (CHREC_RIGHT (*chrec_b)))
> + return false;
> +
> type = chrec_type (*chrec_a);
> left_a = CHREC_LEFT (*chrec_a);
> left_b = chrec_convert (type, CHREC_LEFT (*chrec_b), NULL);
In fact initialize_matrix_A relies on the value fitting an int ...
I'll see to a better fix.