aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Biener <rguenther@suse.de>2015-08-28 07:47:37 +0000
committerRichard Biener <rguenth@gcc.gnu.org>2015-08-28 07:47:37 +0000
commit9ba01f82042079dcdaf74b747ec5d96789e77e72 (patch)
treec32e036fe086ac08df078f6e0ffa56d232e30645 /gcc
parentcae4063ceaad71f86684bf46a6d6443a730ec91b (diff)
downloadgcc-9ba01f82042079dcdaf74b747ec5d96789e77e72.zip
gcc-9ba01f82042079dcdaf74b747ec5d96789e77e72.tar.gz
gcc-9ba01f82042079dcdaf74b747ec5d96789e77e72.tar.bz2
cgraphunit.c (symbol_table::compile): Move early debug generation and finish...
2015-08-28 Richard Biener <rguenther@suse.de> * cgraphunit.c (symbol_table::compile): Move early debug generation and finish... (symbol_table::finalize_compilation_unit): ... back here and add a !seen_error () guard. From-SVN: r227293
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog7
-rw-r--r--gcc/cgraphunit.c23
2 files changed, 20 insertions, 10 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d77e442..8a40fd2 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,10 @@
+2015-08-28 Richard Biener <rguenther@suse.de>
+
+ * cgraphunit.c (symbol_table::compile): Move early debug generation
+ and finish...
+ (symbol_table::finalize_compilation_unit): ... back here and
+ add a !seen_error () guard.
+
2015-08-27 Sebastian Pop <s.pop@samsung.com>
* toplev.c (process_options): Do not use flag_loop_block,
diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c
index cdec63b..be16f5d 100644
--- a/gcc/cgraphunit.c
+++ b/gcc/cgraphunit.c
@@ -2314,16 +2314,6 @@ symbol_table::compile (void)
symtab_node::verify_symtab_nodes ();
#endif
- /* Emit early debug for reachable functions, and by consequence,
- locally scoped symbols. */
- struct cgraph_node *cnode;
- FOR_EACH_FUNCTION_WITH_GIMPLE_BODY (cnode)
- (*debug_hooks->early_global_decl) (cnode->decl);
-
- /* Clean up anything that needs cleaning up after initial debug
- generation. */
- (*debug_hooks->early_finish) ();
-
timevar_push (TV_CGRAPHOPT);
if (pre_ipa_mem_report)
{
@@ -2492,6 +2482,19 @@ symbol_table::finalize_compilation_unit (void)
/* Gimplify and lower thunks. */
analyze_functions (/*first_time=*/false);
+ if (!seen_error ())
+ {
+ /* Emit early debug for reachable functions, and by consequence,
+ locally scoped symbols. */
+ struct cgraph_node *cnode;
+ FOR_EACH_FUNCTION_WITH_GIMPLE_BODY (cnode)
+ (*debug_hooks->early_global_decl) (cnode->decl);
+
+ /* Clean up anything that needs cleaning up after initial debug
+ generation. */
+ (*debug_hooks->early_finish) ();
+ }
+
/* Finally drive the pass manager. */
compile ();