This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug fortran/20923] gfortran slow for large array constructors
- From: "jvdelisle at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 30 Nov 2009 03:59:52 -0000
- Subject: [Bug fortran/20923] gfortran slow for large array constructors
- References: <bug-20923-6528@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #22 from jvdelisle at gcc dot gnu dot org 2009-11-30 03:59 -------
Ok, if I back up one step and leave the error message in trans-array.c and use
gfc_fatal_error we get a usable patch. One thing this is showing is that the
expansion is being done in the parsing/matching phase of compilation and also
in the resolution phase. I do not yet understand why the ICE is triggered
after the error: (with the changes I have made elsewhere.)
if (c->iterator)
{
/* Problems occur when we get something like
integer :: a(lots) = (/(i, i=1, lots)/) */
gfc_error_now ("The number of elements in the array constructor "
"at %L requires an increase of the allowed %d "
"upper limit. See -fmax-array-constructor "
"option", &expr->where,
gfc_option.flag_max_array_constructor);
return NULL_TREE;
}
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20923