[Bug fortran/38672] [4.3/4.4 Regression] ICE during build with versions 4.3.2 and 4.4-20081226
burnus at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Dec 30 16:51:00 GMT 2008
------- Comment #3 from burnus at gcc dot gnu dot org 2008-12-30 16:50 -------
Works with 4.2.1 (x86_64-suse-linux). Valgrind shows:
==27337== Invalid read of size 1
==27337== at 0x4752E2: resolve_symbol (resolve.c:9311)
==27337== by 0x482726: traverse_ns (symbol.c:3127)
==27337== by 0x482715: traverse_ns (symbol.c:3124)
==27337== by 0x482715: traverse_ns (symbol.c:3124)
==27337== by 0x470A3F: resolve_types (resolve.c:10428)
That seems to be:
if (sym->ts.type == BT_DERIVED
&& sym->ts.derived->attr.use_assoc
&& sym->ns->proc_name->attr.flavor == FL_MODULE)
The problem is that for sym->name == "pdm_bps":
(gdb) p sym->ts.type
$3 = BT_DERIVED
(gdb) p sym->ts.derived->attr.use_assoc
$4 = 1
(gdb) p sym->ns->proc_name
$5 = (struct gfc_symbol *) 0x0
Thus there is no surprise that sym->ns->proc_name->attr.flavor gives an ICE.
Note:
(gdb) p sym->attr.flavor
$7 = FL_VARIABLE
The line was added as part of the following commit:
r133488 | pault | 2008-03-24 20:11:24 +0100 (Mon, 24. Mar 2008) | 21 lines
2008-03-24 Paul Thomas <pault@gcc.gnu.org>
PR fortran/34813
* resolve.c (resolve_structure_cons): It is an error to assign
NULL to anything other than a pointer or allocatable component.
PR fortran/33295
* resolve.c (resolve_symbol): If the symbol is a derived type,
resolve the derived type. If the symbol is a derived type
function, ensure that the derived type is visible in the same
namespace as the function.
--
burnus at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |burnus at gcc dot gnu dot
| |org
Status|UNCONFIRMED |NEW
Ever Confirmed|0 |1
GCC build triplet|i686-pc-linux-gnu |
GCC host triplet|i686-pc-linux-gnu |
GCC target triplet|i686-pc-linux-gnu |
Keywords| |ice-on-valid-code
Priority|P3 |P4
Last reconfirmed|0000-00-00 00:00:00 |2008-12-30 16:50:22
date| |
Summary|ICE during build with |[4.3/4.4 Regression] ICE
|versions 4.3.2 and 4.4- |during build with versions
|20081226 |4.3.2 and 4.4-20081226
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38672
More information about the Gcc-bugs
mailing list