I get a reduced test case for this bug. Attached here.
segv fault is cause by following code snip in cp/mangle.c
static tree
mangle_decl_string (const tree decl)
{
...
input_location = DECL_SOURCE_LOCATION (decl); // input_location is ZERO
...
write_mangled_name (decl, true); // Segv fault is triggers in child
calls.
}
The decl is __PRETTY_FUNCTION__, and input_location on FSF 4.5 is NOT
zero. DECL_SOURCE_LOCATION should return non-zero value for
__PRETTY_FUNCTION__, so that it could be mangled.
I get a reduced test case for this bug. Attached here.
segv fault is cause by following code snip in cp/mangle.c
static tree LOCATION (decl); // input_location is ZERO mangled_ name (decl, true); // Segv fault is triggers in child
mangle_decl_string (const tree decl)
{
...
input_location = DECL_SOURCE_
...
write_
calls.
}
This piece of code is backported from gcc 4.5 to fix GCC PR42748, gcc.gnu. org/bugzilla/ show_bug. cgi?id= 42748
http://
The decl is __PRETTY_ FUNCTION_ _, and input_location on FSF 4.5 is NOT LOCATION should return non-zero value for FUNCTION_ _, so that it could be mangled.
zero. DECL_SOURCE_
__PRETTY_
Still investigating it.