Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Josef Zlomek <zlomj9am@artax.karlin.mff.cuni.cz>
To: gcc@gcc.gnu.org, gdb@sources.redhat.com
Subject: GDB does not show variables in inlined function
Date: Tue, 06 Jan 2004 14:49:00 -0000	[thread overview]
Message-ID: <20040106144950.GA18492@artax.karlin.mff.cuni.cz> (raw)

Hello,

when using current GCC mainline and a function gets inlined
(by -funit-at-a-time)
GDB can't show variables of inlined function
(No symbol "incoming" in current context.)

The relevant part of debug info:

without inlining:

        .uleb128 0x25   # (DIE (0x458a) DW_TAG_variable)
        .long   .LASF986        # DW_AT_name: "incoming"
        .byte   0x1     # DW_AT_decl_file
        .value  0x3f32  # DW_AT_decl_line
        .long   0x2d    # DW_AT_type
        .byte   0x1     # DW_AT_location
        .byte   0x55    # DW_OP_reg5

with inlining:

        .uleb128 0x2c   # (DIE (0x2a5a) DW_TAG_variable)
        .long   0x2af2  # DW_AT_abstract_origin
                ^^^^^^
        .byte   0x1     # DW_AT_location
        .byte   0x56    # DW_OP_reg6
...
        .long   0x2d    # DW_AT_type
        .uleb128 0x24   # (DIE (0x2af2) DW_TAG_variable)
                                ^^^^^^
        .long   .LASF850        # DW_AT_name: "incoming"
        .byte   0x1     # DW_AT_decl_file
        .value  0x3f32  # DW_AT_decl_line
        .long   0x2d    # DW_AT_type

The location seems not to be generated for the real variable record
(2nd part after ...) with inlining.

Should GCC generate the location for the second part (after ...) too,
should GDB be able to link the descriptions through the marked number
or something else?

Thanks.

Josef


             reply	other threads:[~2004-01-06 14:49 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-01-06 14:49 Josef Zlomek [this message]
2004-01-06 15:02 ` Daniel Jacobowitz
2004-01-06 15:27   ` Josef Zlomek
2004-01-06 16:23     ` Daniel Jacobowitz
2004-01-06 16:33       ` Josef Zlomek
2004-01-06 16:36         ` Daniel Jacobowitz
2004-01-09  0:13           ` Jim Blandy
2004-01-09  0:15             ` Daniel Jacobowitz

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=20040106144950.GA18492@artax.karlin.mff.cuni.cz \
    --to=zlomj9am@artax.karlin.mff.cuni.cz \
    --cc=gcc@gcc.gnu.org \
    --cc=gdb@sources.redhat.com \
    /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