* [committed] Print cu_offset for --devel-dump-pus
@ 2021-03-16 16:04 Tom de Vries
0 siblings, 0 replies; only message in thread
From: Tom de Vries @ 2021-03-16 16:04 UTC (permalink / raw)
To: dwz, jakub, mark
Hi,
While working on PR27578 I used --devel-dump-edges to identify a problem:
...
idx: 48
cu: 0xbc
incoming: 200
incoming: 201
incoming: 201
incoming: 203
incoming: 204
incoming: 208
...
but I had difficulty relating back the PU with idx 48 to a PU as printed by
--devel-dump-pus.
By adding the printing of the cu_offset for --devel-dump-pus, we have:
...
-Partial unit (phase two):
+Partial unit (phase two) @ 0xbc:
611f5 O 2de8b1f3(deb4b00f) 2de8b1f3 Visual structure_type
...
and it's clear what PU is meant.
Committed to trunk.
Thanks,
- Tom
Print cu_offset for --devel-dump-pus
2021-03-16 Tom de Vries <tdevries@suse.de>
* dwz.c (partition_dups_1): Print cu_offset for --devel-dump-pus.
---
dwz.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/dwz.c b/dwz.c
index d72ec28..7a5d7a3 100644
--- a/dwz.c
+++ b/dwz.c
@@ -8250,12 +8250,13 @@ partition_dups_1 (dw_die_ref *arr, size_t nr_partitions, size_t *partitions,
else
stats->pu_ph2_cnt++;
}
- if (dump_pus_p)
- fprintf (stderr, "Partial unit (%s):\n",
- second_phase ? "phase two" : "phase one");
partial_cu->cu_kind = CU_PU;
partial_cu->cu_offset = *last_partial_cu == NULL
? 0 : (*last_partial_cu)->cu_offset + 1;
+ if (dump_pus_p)
+ fprintf (stderr, "Partial unit (%s) @ 0x%x:\n",
+ second_phase ? "phase two" : "phase one",
+ partial_cu->cu_offset);
partial_cu->cu_version = refcu->cu_version;
if (uni_lang_p)
partial_cu->lang = refcu->lang;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-03-16 16:04 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-16 16:04 [committed] Print cu_offset for --devel-dump-pus Tom de Vries
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).