public inbox for
 help / color / mirror / Atom feed
From: "vries at gcc dot" <>
Subject: [Bug default/24274] New: low-mem files processed in multifile mode
Date: Tue, 01 Jan 2019 00:00:00 -0000	[thread overview]
Message-ID: <> (raw)

            Bug ID: 24274
           Summary: low-mem files processed in multifile mode
           Product: dwz
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: default
          Assignee: nobody at sourceware dot org
          Reporter: vries at gcc dot
                CC: dwz at sourceware dot org
  Target Milestone: ---

Consider four executables, a.out and b.out a hello world example, and c.out and
d.out copied from the dwz executable itself:
$ gcc hello.c -g ; cp a.out b.out
$ cp dwz c.out ; cp c.out d.out

This gives us two executables with 130 DIEs, and two executables with 5356
$ readelf -w a.out | grep '(DW_TAG' | wc -l
$ readelf -w b.out | grep '(DW_TAG' | wc -l
$ readelf -w c.out | grep '(DW_TAG' | wc -l
$ readelf -w d.out | grep '(DW_TAG' | wc -l

Now consider a gdb script that traces the dwz invocations:
$ cat gdb.script
b dwz

We run in multifile mode, with a low-mem limit of 1000 dies, and trace into
$ gdb \
    -batch \
    -x gdb.script \
    --args dwz -m3 -l1000 a.out b.out c.out d.out \
    > LOG 2>&1

which we then summarize as follows:
$ grep 'dwz (' LOG | awk '{print $5}'

The first 6 invocations are according to plan:
- a.out and b.out have fewer DIEs than 1000, and are processed.
- c.out and d.out have more DIEs than 1000, and are each processed twice:
  - once in regular mode (where dwz stops at a 1000 processed DIEs and returns
    2), and 
  - once in low-mem mode.

However, then all 4 files are once more processed in fi_multifile mode, while
the intention is that c.out and d.out (being bigger than the low-mem limit) are
not processed anymore.

You are receiving this mail because:
You are on the CC list for the bug.

             reply	other threads:[~2019-02-27  9:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-01  0:00 vries at gcc dot [this message]
2019-01-01  0:00 ` [Bug default/24274] " vries at gcc dot
2019-01-01  0:00 ` vries at gcc dot
2019-01-01  0:00 ` vries at gcc dot
2021-02-19  0:08 ` mark at klomp dot org

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:

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

  git send-email \ \ \ \

* 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).