From: Jakub Jelinek <jakub@redhat.com>
To: Mark Wielaard <mark@klomp.org>
Cc: dwz@sourceware.org
Subject: Re: [PATCH] Support updating DWARF5 .debug_loclists.
Date: Tue, 29 Sep 2020 10:42:23 +0200 [thread overview]
Message-ID: <20200929084223.GX2176@tucnak> (raw)
In-Reply-To: <20200928080759.8619-1-mark@klomp.org>
On Mon, Sep 28, 2020 at 10:07:59AM +0200, Mark Wielaard wrote:
> ptr += offset;
> while (ptr < endsec)
> {
> - low = read_size (ptr, ptr_size);
> - high = read_size (ptr + ptr_size, ptr_size);
> - ptr += 2 * ptr_size;
> - if (low == 0 && high == 0)
> - break;
> + if (cu->cu_version < 5)
I wonder if it wouldn't be clearer to use sec == DEBUG_LOC
in this spot (i.e. leave the decision based on cu_version just to the
start of the function).
> + case DW_LLE_start_length:
> + ptr += ptr_size;
> + skip_leb128 (ptr);
> + len = read_uleb128 (ptr);
> + break;
Wonder if we shouldn't handle case DW_LLE_GNU_view_part here, but perhaps
only for cu->cu_version == 5 because it isn't in a separate vendor code
space and thus in DWARF 6 it could mean something different.
> while (ptr < endsec)
> {
> - low = read_size (ptr, ptr_size);
> - high = read_size (ptr + ptr_size, ptr_size);
> - ptr += 2 * ptr_size;
> - if (low == 0 && high == 0)
> - break;
> + if (cu->cu_version < 5)
Ditto.
> + case DW_LLE_start_length:
> + ptr += ptr_size;
> + skip_leb128 (ptr);
> + len = read_uleb128 (ptr);
> + break;
Ditto.
Otherwise LGTM.
Jakub
next prev parent reply other threads:[~2020-09-29 8:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-28 8:07 Mark Wielaard
2020-09-29 8:42 ` Jakub Jelinek [this message]
2020-09-29 17:59 ` Mark Wielaard
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=20200929084223.GX2176@tucnak \
--to=jakub@redhat.com \
--cc=dwz@sourceware.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).