From a418679d8d389c0960a17eded96bb9ddb7e33cb6 Mon Sep 17 00:00:00 2001 From: Jan Hubicka Date: Thu, 24 Aug 2006 15:30:45 +0200 Subject: re PR debug/26881 (internal compiler error in dwarf2out_finish) PR debug/26881 * cgraph.c: Fix comments. (cgraph_varpool_mark_needed_node): Mark only variables not already output to file. * cgraphunit.c: Update comments; include gt-cgraphunit.h (cgraph_varpool_assembled_nodes_queue): New static variable. (cgraph_varpool_assemble_decl): Record output decls for debug out code. (cgraph_varpool_output_debug_info): New function. (cgraph_finalize_compilation_unit, cgraph_optimize): Call it. * Makefile.in: Add gt-cgraphunit.h * gcc.dg/debug/pr26881.c: New file. From-SVN: r116374 --- gcc/cgraph.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'gcc/cgraph.c') diff --git a/gcc/cgraph.c b/gcc/cgraph.c index dc98ccf0958..372b90d5eaa 100644 --- a/gcc/cgraph.c +++ b/gcc/cgraph.c @@ -47,9 +47,9 @@ The callgraph: be accessed in such an invisible way and it shall be considered an entry point to the callgraph. - Intraprocedural information: + Interprocedural information: - Callgraph is place to store data needed for intraprocedural optimization. + Callgraph is place to store data needed for interprocedural optimization. All data structures are divided into three components: local_info that is produced while analyzing the function, global_info that is result of global walking of the callgraph on the end of compilation and @@ -921,7 +921,8 @@ cgraph_varpool_reset_queue (void) void cgraph_varpool_mark_needed_node (struct cgraph_varpool_node *node) { - if (!node->needed && node->finalized) + if (!node->needed && node->finalized + && !TREE_ASM_WRITTEN (node->decl)) cgraph_varpool_enqueue_needed_node (node); node->needed = 1; } -- cgit v1.2.1