From: Tom Tromey <tom@tromey.com>
To: gdb-patches@sourceware.org
Cc: Tom Tromey <tom@tromey.com>
Subject: [PATCH] Start abbrevs at 1 in DWARF assembler
Date: Tue, 5 Dec 2023 14:23:06 -0700 [thread overview]
Message-ID: <20231205212306.1438059-1-tom@tromey.com> (raw)
I noticed that the DWARF assembler starts abbrevs at 2.
I think 1 should be preferred.
---
gdb/testsuite/lib/dwarf.exp | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/gdb/testsuite/lib/dwarf.exp b/gdb/testsuite/lib/dwarf.exp
index f09da0430ab..19c89c048fe 100644
--- a/gdb/testsuite/lib/dwarf.exp
+++ b/gdb/testsuite/lib/dwarf.exp
@@ -564,8 +564,8 @@ namespace eval Dwarf {
# for Fission.
variable _abbrev_section
- # The next available abbrev number in the current CU's abbrev
- # table.
+ # The most recently assigned abbrev number in the current CU's
+ # abbrev table.
variable _abbrev_num
# The string table for this assembly. The key is the string; the
@@ -1485,7 +1485,7 @@ namespace eval Dwarf {
set cu_num [incr _cu_count]
set my_abbrevs [_compute_label "abbrev${cu_num}_begin"]
- set _abbrev_num 1
+ set _abbrev_num 0
set _cu_label [_compute_label "cu${cu_num}_begin"]
set start_label [_compute_label "cu${cu_num}_start"]
@@ -1597,7 +1597,7 @@ namespace eval Dwarf {
set cu_num [incr _cu_count]
set my_abbrevs [_compute_label "abbrev${cu_num}_begin"]
- set _abbrev_num 1
+ set _abbrev_num 0
set _cu_label [_compute_label "cu${cu_num}_begin"]
set start_label [_compute_label "cu${cu_num}_start"]
--
2.43.0
next reply other threads:[~2023-12-05 21:23 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-05 21:23 Tom Tromey [this message]
2023-12-06 14:38 ` Tom de Vries
2023-12-06 15:41 ` Tom Tromey
2023-12-06 16:27 ` Tom de Vries
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=20231205212306.1438059-1-tom@tromey.com \
--to=tom@tromey.com \
--cc=gdb-patches@sourceware.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).