public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Eric Botcazou <ebotcazou@adacore.com>
To: Aldy Hernandez <aldyh@redhat.com>
Cc: gcc-patches@gcc.gnu.org, jason merrill <jason@redhat.com>
Subject: Re: [patch 1/10] debug-early merge: Ada front-end
Date: Fri, 22 May 2015 08:52:00 -0000	[thread overview]
Message-ID: <4551502.qkiKH4tKPB@polaris> (raw)
In-Reply-To: <555E4C87.9040804@redhat.com>

> My apologies for the delay on Ada.  I have reworked the patch to leave
> the first pass on the TYPE_DECLs which are definitely needed.  I also
> optimized things a bit, since we don't need to save all the globals any
> more.

Thanks, this looks fine modulo a couple of nits, see below.

> There is one regression which I'd like you and Jason's input before
> proceeding:
> 
> +FAIL: gnat.dg/specs/debug1.ads scan-assembler-times DW_AT_artificial 17
> 
> The problem is that the Ada front-end twiddles the DECL_ARTIFICIAL flag
> *after* it has called debug_hooks->early_global_decl().  The function
> gnat_to_gnu_entity() calls create_var_decl_1->rest_of_decl_compilation,
> but then much later twiddles DECL_ARTIFICIAL:
> 
>        if (!Comes_From_Source (gnat_entity))
> 	DECL_ARTIFICIAL (gnu_decl) = 1;
> 
> Twiddling DECL_ARTIFICIAL after we create early dwarf, means the DIE
> does not get the DW_AT_artificial.  Would it be possible for you guys
> (ahem, Ada folk) to set DECL_ARTIFICIAL before calling
> rest_of_decl_compilation?

Sure, just add a ??? comment before the above lines for now.


@@ -535,8 +535,7 @@ extern tree gnat_type_for_size (unsigned precision, int 
unsignedp);
    an unsigned type; otherwise a signed type is returned.  */
 extern tree gnat_type_for_mode (machine_mode mode, int unsignedp);
 
-/* Emit debug info for all global variable declarations.  */
-extern void gnat_write_global_declarations (void);
+extern void note_types_used_by_globals (void);

The comment needs to be adjusted instead of removed and preferably be the same 
as the one (ajusted too) above the function in utils.c.

-- 
Eric Botcazou

  reply	other threads:[~2015-05-22  8:33 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-08  0:32 Aldy Hernandez
2015-05-08 10:27 ` Eric Botcazou
2015-05-08 10:35   ` Richard Biener
2015-05-08 15:22     ` Aldy Hernandez
2015-05-09 11:31       ` Eric Botcazou
2015-05-08 16:23   ` Aldy Hernandez
2015-05-09 11:31     ` Eric Botcazou
2015-05-21 21:33   ` Aldy Hernandez
2015-05-22  8:52     ` Eric Botcazou [this message]
2015-05-22 12:33       ` Aldy Hernandez

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4551502.qkiKH4tKPB@polaris \
    --to=ebotcazou@adacore.com \
    --cc=aldyh@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jason@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).