From: Daniel Jacobowitz <drow@false.org>
To: Carl Burch <cdb@cup.hp.com>
Cc: gdb@sourceware.org
Subject: Re: DWARF-2 expression error in location list entries
Date: Tue, 08 May 2007 20:36:00 -0000 [thread overview]
Message-ID: <20070508203549.GA17019@caradoc.them.org> (raw)
In-Reply-To: <200705082022.NAA04796@hpadl693.cup.hp.com>
On Tue, May 08, 2007 at 01:22:25PM -0700, Carl Burch wrote:
> In dwarf2expr.c function execute_stack_op() there are two occurrences of
> error() calls asserting :
>
> if (op_ptr != op_end && *op_ptr != DW_OP_piece)
> error (_("DWARF-2 expression error: DW_OP_reg operations must be "
> "used either alone or in conjuction with DW_OP_piece."));
>
> A couple of us have looked for that first restriction in the DWARF3
> standard and not found it. I also went back to the DWARF2 standard
> literally cited by the message and failed to find it there as well. Can
> anyone point out where to read the restriction these error() calls refer to?
I believe the language was recently discussed on the dwarf workgroup
list. It's unclear, but the error is correct. DW_OP_regx describes
a location ("the value is in this register"), not a value ("the value is
the contents of this register"). Therefore the value may not be
stack-sized, and is not pushed on to the expression stack, so there's
nothing for you to DW_OP_deref later.
> The expression we have in mind to add is to describe Fortran reference
> parameters in location list entries like :
>
> { 0x4022720--0x4022724: DW_OP_regx 32 DW_OP_deref }
Isn't that just "DW_OP_bregx 32 0"?
--
Daniel Jacobowitz
CodeSourcery
next prev parent reply other threads:[~2007-05-08 20:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-08 20:22 Carl Burch
2007-05-08 20:36 ` Daniel Jacobowitz [this message]
2007-05-08 22:49 Carl Burch
2007-05-08 23:51 ` Daniel Jacobowitz
2007-05-10 1:21 David Anderson
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=20070508203549.GA17019@caradoc.them.org \
--to=drow@false.org \
--cc=cdb@cup.hp.com \
--cc=gdb@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