re PR debug/86413 (gcc.dg/guality/pr48437.c fail)
authorRichard Biener <rguenther@suse.de>
Mon, 9 Jul 2018 07:25:14 +0000 (07:25 +0000)
committerRichard Biener <rguenth@gcc.gnu.org>
Mon, 9 Jul 2018 07:25:14 +0000 (07:25 +0000)
2018-07-09  Richard Biener  <rguenther@suse.de>

PR debug/86413
* dwarf2out.c (gen_block_die): For an early generated DIE
always output high/low PC attributes.

From-SVN: r262511

gcc/ChangeLog
gcc/dwarf2out.c

index 8add29b..4295d5f 100644 (file)
@@ -1,3 +1,9 @@
+2018-07-09  Richard Biener  <rguenther@suse.de>
+
+       PR debug/86413
+       * dwarf2out.c (gen_block_die): For an early generated DIE
+       always output high/low PC attributes.
+
 2018-07-09  Tom de Vries  <tdevries@suse.de>
 
        * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
index a7c4620..9523217 100644 (file)
@@ -25622,6 +25622,11 @@ gen_block_die (tree stmt, dw_die_ref context_die)
     /* The outer scopes for inlinings *must* always be represented.  We
        generate DW_TAG_inlined_subroutine DIEs for them.  (See below.) */
     must_output_die = 1;
+  else if (BLOCK_DIE (stmt))
+    /* If we already have a DIE then it was filled early.  Meanwhile
+       we might have pruned all BLOCK_VARS as optimized out but we
+       still want to generate high/low PC attributes so output it.  */
+    must_output_die = 1;
   else
     {
       /* Determine if this block directly contains any "significant"