public inbox for dwz@sourceware.org
 help / color / mirror / Atom feed
From: Tom de Vries <tdevries@suse.de>
To: Mark Wielaard <mark@klomp.org>, dwz@sourceware.org, jakub@redhat.com
Cc: Mark Wielaard <mark@gcc.gnu.org>
Subject: Re: [PATCH] Print die_hash2 for --odr --devel-dump-dies
Date: Thu, 18 Feb 2021 21:48:13 +0100	[thread overview]
Message-ID: <ee2ec7f9-4922-be4b-f33e-2654a14ceaa0@suse.de> (raw)
In-Reply-To: <d78e7f82c15ad12152b1b1c9b753f25278702c9d.camel@klomp.org>

On 2/18/21 4:03 PM, Mark Wielaard wrote:
> Hi Tom,
> 
> On Mon, 2021-02-15 at 21:34 +0100, Tom de Vries wrote:
>> For --odr, there's an additional hash value, die->u.p1.die_hash2.
>>
>> Print this with --devel-dump-dies, such that we have:
>> ...
>> $ dwz --devel-dump-dies --odr odr-struct
>>   114 O f56004ac(cd46c7ab) f56004ac aaa structure_type
>>   ...
>>   1ba O f56004ac(cd46c7ab) f56004ac aaa structure_type
>> ...
>>
>> Used to debug PR27400.
>>
>> Any comments?
> 
> Obviously this is useful.
> But I always forget how to use these --devel flags.
> 
> They are only in the dwz-for-test binary, which isn't build by default,

Hi Mark,

they're only defined when building with -DDEVEL.  Which is enabled in
dwz-for-test (which is enabled by default in the testsuite), but also in
my usual build command.

> and seems to have some subtle other differences, like undefining
> __GNUC__?
> 

That's just a ploy to get both the -D__GNUC__ and -U__GNUC__ paths
exercised.  It's not really specific to -DDEVEL.

> Is there more documentation on the --devel flags/binary

Nope.

> or is this just
> meant for people directly hacking on dwz in the git repo?

Yep.

The idea was to move all hacky stuff (like f.i -DDEBUG_DUMP_DIES) to
command line switches under -DDEVEL, such that you have two versions:
- the official one, -UDEVEL, without anything slowing dwz down, or
  exposing unstable interfaces to users, and
- the development one, -DDEVEL, with the perks of extra traces
  and switches to influence behaviour, but possible slower and
  experimental.

HTH,
- Tom

      reply	other threads:[~2021-02-18 20:48 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-15 20:34 Tom de Vries
2021-02-18 15:03 ` Mark Wielaard
2021-02-18 20:48   ` Tom de Vries [this message]

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=ee2ec7f9-4922-be4b-f33e-2654a14ceaa0@suse.de \
    --to=tdevries@suse.de \
    --cc=dwz@sourceware.org \
    --cc=jakub@redhat.com \
    --cc=mark@gcc.gnu.org \
    --cc=mark@klomp.org \
    /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).