Mark Wielaard 66eaae9bcc libdw: Add new function dwarf_getlocations.
Using dwarf_getlocation it is possible to get single location
descriptions and with dwarf_getlocation_addr it is possible to
get a location list covering a specific address.  But sometimes
it is more convenient to get all ranges covered by a location
list.  For example when a specific address isn't covered and
you want to find alternative addresses where a location
description is defined.

dwarf_getlocations is modelled after dwarf_ranges. It enumerates
the location ranges and descriptions covered by the given
attribute.  In the first call OFFSET should be zero and *BASEP
need not be initialized.  Returns -1 for errors, zero when
there are no more locations to report, or a nonzero OFFSET
value to pass to the next call.  Each subsequent call must
preserve *BASEP from the prior call.  Successful calls fill in
*STARTP and *ENDP with a contiguous address range and *EXPR with
a pointer to an array of operations with length *EXPRLEN.  If
the attribute describes a single location description and not a
location list the first call (with OFFSET zero) will return the
location description in *EXPR with *STARTP set to zero and *ENDP
set to minus one.

ptrdiff_t dwarf_getlocations (Dwarf_Attribute *attr, ptrdiff_t offset,
                              Dwarf_Addr *basep, Dwarf_Addr *startp,
                              Dwarf_Addr *endp, Dwarf_Op **expr,
                              size_t *exprlen);

Signed-off-by: Mark Wielaard <mjw@redhat.com>
2013-09-06 12:09:45 +02:00
2013-09-03 11:43:19 +02:00
2013-07-25 11:17:49 +02:00
2013-04-30 14:25:18 +02:00
2013-04-26 10:06:08 +02:00
2013-04-26 10:06:08 +02:00
2013-04-26 10:06:08 +02:00
2013-08-28 18:58:10 +02:00
2013-04-26 10:06:08 +02:00
2013-07-25 11:17:49 +02:00
2013-09-03 11:43:19 +02:00
2013-04-26 10:06:08 +02:00
2009-01-10 18:17:09 -08:00
2013-07-25 11:17:49 +02:00
2013-07-25 11:17:49 +02:00
2013-08-21 10:41:12 +02:00
2005-07-26 05:00:05 +00:00
2005-07-26 05:00:05 +00:00
2009-01-24 17:16:39 -08:00
2009-01-10 18:17:09 -08:00

Fundamental design decision:

- the sizes of external and internal types are assumed to be the same.
  This leaves byte ordering aside.  While assuming this the code can be
  greatly simplified and speed increases.  Since no change violating this
  assumption is in sight this is believed to be a worthwhile optimization.

- the ABI of the backend modules is not guaranteed.  Really, not guarantee
  whatsoever.  We are enforcing this in the code.  The modules and their
  users must match.  No third-party EBL module are supported or allowed.
  The only reason there are separate modules is to not have the code for
  all architectures in all the binaries.
S
Description
暂无描述
Readme 23 MiB
Languages
C 70.8%
Shell 22.6%
C++ 3.3%
Makefile 1.4%
M4 1%
Other 0.8%