diff options
author | Richard Biener <rguenther@suse.de> | 2018-01-10 14:23:29 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2018-01-10 14:23:29 +0000 |
commit | 31a3f58f9bc947ecf3d59eb210199a3e5ca0b49f (patch) | |
tree | 68fd52e3dcb67e1450deafc59606df3faa1582d8 /gcc | |
parent | 6737facbb3c53a1f0158b05e4116c161ed9bc319 (diff) | |
download | gcc-31a3f58f9bc947ecf3d59eb210199a3e5ca0b49f.zip gcc-31a3f58f9bc947ecf3d59eb210199a3e5ca0b49f.tar.gz gcc-31a3f58f9bc947ecf3d59eb210199a3e5ca0b49f.tar.bz2 |
re PR debug/83765 (LTO bootstrap with Ada fails)
2018-01-10 Richard Biener <rguenther@suse.de>
PR debug/83765
* dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
early out so it also covers the case where we have a non-NULL
origin.
From-SVN: r256428
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/dwarf2out.c | 10 |
2 files changed, 12 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index f0e9e59..01a89c72 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2018-01-10 Richard Biener <rguenther@suse.de> + + PR debug/83765 + * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration + early out so it also covers the case where we have a non-NULL + origin. + 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org> PR tree-optimization/83753 diff --git a/gcc/dwarf2out.c b/gcc/dwarf2out.c index a34b294..b70856f 100644 --- a/gcc/dwarf2out.c +++ b/gcc/dwarf2out.c @@ -22044,6 +22044,11 @@ gen_subprogram_die (tree decl, dw_die_ref context_die) int declaration = (current_function_decl != decl || class_or_namespace_scope_p (context_die)); + /* A declaration that has been previously dumped needs no + additional information. */ + if (old_die && declaration) + return; + /* Now that the C++ front end lazily declares artificial member fns, we might need to retrofit the declaration into its class. */ if (!declaration && !origin && !old_die @@ -22084,11 +22089,6 @@ gen_subprogram_die (tree decl, dw_die_ref context_die) much as possible. */ else if (old_die) { - /* A declaration that has been previously dumped needs no - additional information. */ - if (declaration) - return; - if (!get_AT_flag (old_die, DW_AT_declaration) /* We can have a normal definition following an inline one in the case of redefinition of GNU C extern inlines. |