Commit 53a5717e by Richard Biener Committed by Richard Biener

re PR debug/59323 (Int. comp. error: in add_AT_specification, at dwarf2out.c:4026)

2013-11-28  Richard Biener  <rguenther@suse.de>

	PR lto/59323
	* lto-streamer-out.c (tree_is_indexable): TYPE_DECLs and
	CONST_DECLs in function context are not indexable.

	* gcc.dg/lto/pr59323_0.c: New testcase.

From-SVN: r205481
parent cceeb9a9
2013-11-28 Richard Biener <rguenther@suse.de>
PR lto/59323
* lto-streamer-out.c (tree_is_indexable): TYPE_DECLs and
CONST_DECLs in function context are not indexable.
2013-11-28 Chung-Ju Wu <jasonwucj@gmail.com>
* config/nds32/nds32.c (nds32_rtx_costs): Adjust MULT cost if it is
......@@ -135,8 +135,10 @@ tree_is_indexable (tree t)
definition. */
if (TREE_CODE (t) == PARM_DECL || TREE_CODE (t) == RESULT_DECL)
return variably_modified_type_p (TREE_TYPE (DECL_CONTEXT (t)), NULL_TREE);
else if (TREE_CODE (t) == VAR_DECL && decl_function_context (t)
&& !TREE_STATIC (t))
else if (((TREE_CODE (t) == VAR_DECL && !TREE_STATIC (t))
|| TREE_CODE (t) == TYPE_DECL
|| TREE_CODE (t) == CONST_DECL)
&& decl_function_context (t))
return false;
else if (TREE_CODE (t) == DEBUG_EXPR_DECL)
return false;
......
2013-11-28 Richard Biener <rguenther@suse.de>
PR lto/59323
* gcc.dg/lto/pr59323_0.c: New testcase.
2013-11-28 Jakub Jelinek <jakub@redhat.com>
PR middle-end/57393
......
/* { dg-lto-do link } */
/* { dg-lto-options { { -O2 -g -flto } } } */
/* { dg-extra-ld-options { -r -nostdlib } } */
extern void bar(void);
int main(int argc, char **argv)
{
int i;
if (argc == 1) {
enum { X };
bar();
{
enum { X };
asm goto ("" : : : : lab);
lab:
;
}
}
{
enum { X };
int foo(void)
{
return argv[0][0];
}
i = foo();
}
return i;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment