Regression with parameter_array_init_3.f90
Steve Kargl
sgk@troutmask.apl.washington.edu
Fri Jan 11 14:14:00 GMT 2008
On Thu, Jan 10, 2008 at 08:06:01AM +0100, Paul Thomas wrote:
> Steve,
> >Sigh. I spent too much time on this today :(, except those associated
> >with endian-ness. Nothing, nada, ne rien...
> >
> I bootstrapped and regtested on x86_ia64/FC8, which normally catches all
> the ailments that are going
> >The segfault is occurring in find_array_element() of expr.c.
> >This function is called 3 times. The first 2 return because
> >e->expr_type in line 1023 is not constant. The third trip into
> >this function I get the segfault. AFAICT, something is
> >messed up with the ar structure. Unfortunately, I can't
> >use gdb to trace into this function (it appears to be inlined).
> >If I try to set a break point on find_array_element, gdb tells
> >me that symbol does not exist!
> >
> >
> I noticed that the backtrace that you posted is a bit odd - line numbers
> and function calls are de-synched. I am at a complete loss to explain
> it. Have you tried clearing your tree to bedrock and rebuilding? Does
> anybody else see it?
>
> Thanks for your efforts.
>
#0 0x000000020100c810 in __gmpn_add_n () from /usr/local/lib/libgmp.so.7
#1 0x0000000200ff912d in __gmpz_add () from /usr/local/lib/libgmp.so.7
#2 0x0000000000423b62 in simplify_const_ref (p=0x201497900)
at ../../gcc4x/gcc/fortran/expr.c:1049
If I look at p in gdb I see
(gdb) print *p->ref->u->ar->as->upper[0]
$14 = {expr_type = EXPR_FUNCTION, ts = {type = BT_UNKNOWN, kind = 0,
derived = 0x0, cl = 0x0, is_c_interop = 0, is_iso_c = 0,
f90_type = BT_UNKNOWN}, rank = 0, shape = 0x0, symtree = 0x201401230,
ref = 0x0, where = {nextc = 0x20148a20f "len(HEX1)) = [(1,i=1,len(HEX1))]",
lb = 0x20148a1d0}, inline_noncopying_intrinsic = 0, is_boz = 0,
con_by_offset = 0x0, representation = {length = 0, string = 0x0}, value = {
logical = 20976224, integer = {{_mp_alloc = 20976224, _mp_size = 2,
_mp_d = 0x0}}, real = {{_mpfr_prec = 8610910816, _mpfr_sign = 0,
_mpfr_exp = 0, _mpfr_d = 0x0}}, complex = {r = {{
_mpfr_prec = 8610910816, _mpfr_sign = 0, _mpfr_exp = 0,
_mpfr_d = 0x0}}, i = {{_mpfr_prec = 0, _mpfr_sign = 0,
_mpfr_exp = 0, _mpfr_d = 0x0}}}, op = {operator = 20976224,
uop = 0x0, op1 = 0x0, op2 = 0x0}, function = {actual = 0x201401260,
name = 0x0, isym = 0x0, esym = 0x0}, character = {length = 20976224,
string = 0x0}, constructor = 0x201401260}}
I'd expect to see some sort of gfc_evaluate_now() for
EXPR_FUNCTION. Intstead, it seems to die while dereferencing
p->ref->u->ar->as->upper[0]->value.integer.
BTW, I've checked gmp and it passes all of its tests.
I'll keep hunting.
--
Steve
More information about the Fortran
mailing list