Skip to content

Commit 318cb65

Browse files
committed
Updated the date to today.
modified: doc/libdwarf.dox Regenerated. modified: doc/libdwarf.pdf Corrected typos in doxygen comments. modified: src/lib/libdwarf/libdwarf.h
1 parent 4071210 commit 318cb65

File tree

3 files changed

+38
-41
lines changed

3 files changed

+38
-41
lines changed

doc/libdwarf.dox

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
@tableofcontents{HTML:3,LaTeX:3}
44
@author David Anderson
55
@copyright This work is licensed under the Creative Commons Attribution 4.0 International License. To view a copy of this license, visit http://creativecommons.org/licenses/by/4.0/ or send a letter to Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.
6-
@date 2022-04-06 v0.4.0
6+
@date 2022-04-07 v0.4.0
77

88
@section draft This is a draft.
99

@@ -63,11 +63,11 @@
6363
Libdwarf can safely open multiple Dwarf_Debug
6464
pointers simultaneously but all such Dwarf_Debug
6565
pointers must be opened within the same thread.
66-
And all libdwarf calls must be made from within
66+
And all @e libdwarf calls must be made from within
6767
that single (same) thread.
6868

69-
@section dwsec_error Error Handling in libdwarf
70-
Essentially every libdwarf call could involve dealing
69+
@section dwsec_error Error Handling in @e libdwarf
70+
Essentially every @e libdwarf call could involve dealing
7171
with an error (possibly data corruption in
7272
the object file). Here we explain the two main
7373
approaches the library provides (though we think
@@ -178,7 +178,7 @@
178178
}
179179
@endcode
180180
because it returns. The DW_DLV_ERROR code
181-
is returned from libdwarf and your code
181+
is returned from @e libdwarf and your code
182182
can do what it likes with the error situation.
183183

184184

@@ -293,7 +293,7 @@
293293
But usually the wasted space, if any, is small.
294294

295295
Compiler writers or others may be interested in looking
296-
at these sections independently so libdwarf provides
296+
at these sections independently so @e libdwarf provides
297297
functions
298298
that allow reading the sections without reference
299299
to what references them.
@@ -312,7 +312,7 @@
312312
But if there is some random data somewhere
313313
outside of referenced areas the reader function
314314
may fail, returning DW_DLV_ERROR.
315-
Such an error is neither a compiler bug nor a libdwarf bug.
315+
Such an error is neither a compiler bug nor a @e libdwarf bug.
316316

317317
@section frameregs Special Frame Registers
318318

@@ -441,7 +441,7 @@
441441
For a simple example of this
442442
@see jitreader
443443

444-
But the libdwarf feature can be used in a wide variety of ways.
444+
But the @e libdwarf feature can be used in a wide variety of ways.
445445

446446
For example, the DWARF data could be kept
447447
in simple files of bytes on the internet.
@@ -460,14 +460,14 @@
460460
a small handful of functions and supply
461461
function pointers and code implementing the
462462
functions. These are part of your application
463-
or library, not part of libdwarf.
463+
or library, not part of @e libdwarf.
464464

465465
You set up a little bit of data with that code
466466
(all described below)
467467
and then you have essentially written the
468468
dwarf_init_path equivalent and you can access
469469
compilation units, line tables etc and
470-
the standard libdwarf function calls simply work.
470+
the standard @e libdwarf function calls simply work.
471471

472472
Data you need to create involves these types.
473473
What follows describes how to fill them in
@@ -522,7 +522,7 @@
522522
@b Dwarf_Obj_Access_Section_a:
523523
Your implementation of a @b om_get_section_info
524524
must simply fill in a few fields (leaving most zero)
525-
for libdwarf. The fields here are standard Elf,
525+
for @e libdwarf. The fields here are standard Elf,
526526
but for most you can just use the value zero.
527527
We assume here you will not be doing relocations
528528
at runtime.
@@ -542,7 +542,7 @@
542542
@b as_offset: Just fill in zero.
543543

544544
@b as_size: Fill in the size, in bytes,
545-
of the section you are telling libdwarf about.
545+
of the section you are telling @e libdwarf about.
546546

547547
@b as_link: Just fill in zero.
548548

@@ -554,7 +554,7 @@
554554

555555
@b Dwarf_Obj_Access_Methods_a_s:
556556
The functions we need to access object data
557-
from libdwarf are declared here.
557+
from @e libdwarf are declared here.
558558

559559
In these function pointer declarations
560560
'void *obj' is intended to be a pointer (the object field in
@@ -564,7 +564,7 @@
564564
it possible to handle multiple object formats
565565
and multiple libraries.
566566
It's not required that one handles multiple such
567-
in a single libdwarf
567+
in a single @e libdwarf
568568
archive/shared-library (but not ruled out either).
569569
See dwarf_elf_object_access_internals_t and dwarf_elf_access.c
570570
for an example.
@@ -608,7 +608,7 @@
608608
#define DW_GROUPNUMBER_DWO 2
609609
@endcode
610610

611-
The DW_GROUPNUMBER_ are used in libdwarf functions
611+
The DW_GROUPNUMBER_ are used in @e libdwarf functions
612612
dwarf_init_path(), dwarf_init_path_dl() and
613613
dwarf_init_b(). In all those cases unless
614614
you know there is any complexity in your object file,
@@ -626,31 +626,31 @@
626626
@see dwarf_sec_group_map
627627

628628
If an object file has multiple groups
629-
libdwarf will not reveal contents of the other
629+
@e libdwarf will not reveal contents of the other
630630
groups.
631631
One must pass in another groupnumber
632632
to dwarf_init_path, meaning init
633-
a new Dwarf_Debug, to get libdwarf to
633+
a new Dwarf_Debug, to get @e libdwarf to
634634
access that group.
635635

636636
When opening a Dwarf_Debug the following applies:
637637

638-
If DW_GROUPNUMBER_ANY is passed in libdwarf will
638+
If DW_GROUPNUMBER_ANY is passed in @e libdwarf will
639639
choose either of DW_GROUPNUMBER_BASE(1) or
640640
DW_GROUPNUMBER_DWO (2) depending on the object
641641
content. If both groups one and two are in the
642-
object libdwarf will chose DW_GROUPNUMBER_BASE.
642+
object @e libdwarf will chose DW_GROUPNUMBER_BASE.
643643

644-
If DW_GROUPNUMBER_BASE is passed in libdwarf
644+
If DW_GROUPNUMBER_BASE is passed in @e libdwarf
645645
will choose it if non-split DWARF is in the object, else
646646
the init call will return DW_DLV_NO_ENTRY.
647647

648-
If DW_GROUPNUMBER_DWO is passed in libdwarf
648+
If DW_GROUPNUMBER_DWO is passed in @e libdwarf
649649
will choose it if .dwo sections are in the object, else
650650
the init will call return DW_DLV_NO_ENTRY.
651651

652652
If a groupnumber greater than two is passed in
653-
libdwarf simply accepts it, whether any sections
653+
@e libdwarf simply accepts it, whether any sections
654654
corresponding to that groupnumber exist or not.
655655

656656
For information on groups "dwarfdump -i"
@@ -669,7 +669,7 @@
669669
(but none in an executable or shared object).
670670
Each such COMDAT group will have a small set of
671671
sections in it and each section in such a group
672-
will be assigned the same group number by libdwarf.
672+
will be assigned the same group number by @e libdwarf.
673673

674674
Sections that are in a .dwp .dwo object file
675675
are assigned to DW_GROUPNUMBER_DWO,
@@ -699,7 +699,7 @@
699699
(but none in an executable or shared object).
700700
Each such COMDAT group will have a small set of
701701
sections in it and each section in such a group
702-
will be assigned the same group number by libdwarf.
702+
will be assigned the same group number by @e libdwarf.
703703

704704
Sections that are in a .dwp .dwo object file
705705
are assigned to DW_GROUPNUMBER_DWO,
@@ -714,7 +714,7 @@
714714

715715
Popular compilers and tools are using such sections. There
716716
is no detailed documentation that we can find (so far)
717-
on how the COMDAT section groups are used, so libdwarf is
717+
on how the COMDAT section groups are used, so @e libdwarf is
718718
based on observations of what compilers generate.
719719

720720
@section dwsec_changes Recent Changes
@@ -752,7 +752,7 @@
752752
Added support for the meson build system.
753753

754754
Updated an include in libdwarfp source files.
755-
Improved doxygen documentation of libdwarf.
755+
Improved doxygen documentation of @e libdwarf.
756756
Now 'make check -j8' and the like works correctly.
757757
Fixed a bug where reading a PE (Windows)
758758
object could fail for certain section

doc/libdwarf.pdf

12.9 KB
Binary file not shown.

src/lib/libdwarf/libdwarf.h

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5978,9 +5978,10 @@ DW_API int dwarf_get_debug_sup(Dwarf_Debug dw_dbg,
59785978
The section is new in DWARF5 supersedes .debug_pubnames and
59795979
.debug_pubtypes in DWARF2, DWARF3, and DWARF4.
59805980
5981-
The existing functions provide a detailed reporting
5982-
of the content and structure of the table, they
5983-
are not intended to be used to search the table.
5981+
The functions provide a detailed reporting
5982+
of the content and structure of the table (so one
5983+
can build one's own search table) but they
5984+
are not particularly helpful for searching.
59845985
59855986
A new function (more than one?) would be needed for convenient
59865987
searching.
@@ -6252,27 +6253,23 @@ DW_API int dwarf_dnames_name(Dwarf_Dnames_Head dw_dn,
62526253
@param dw_tag
62536254
If non-null and the call succeeds, the DW_TAG value
62546255
applying to this abbreviation is returned.
6255-
@param dw_index_of_abbrev,
6256+
@param dw_index_of_abbrev
62566257
If non-null and the call succeeds, the index number
62576258
assigned by libdwarf to this abbrev set is returned.
62586259
The numbers are sequential, 0,1, etc.
6259-
@param dw_number_of_attr_form_entries;
6260+
The trailing 0,0 pair is counted.
6261+
@param dw_number_of_attr_form_entries
62606262
If non-null and the call succeeds, number of
62616263
attribute-form pairs in this abbrev is returned.
62626264
The count includes the terminationg 0,0 pair.
62636265
@return
62646266
Returns either DW_DLV_OK or, if the abbrev code is
6265-
not found returns DW_DLV_NO_ENTRY.
6267+
not found, returns DW_DLV_NO_ENTRY.
62666268
*/
62676269
DW_API int dwarf_dnames_abbrev_by_code(Dwarf_Dnames_Head dw_dn,
62686270
Dwarf_Half dw_abbrev_code,
62696271
Dwarf_Half * dw_tag,
6270-
6271-
/* The number of this code/tag as an array index. */
62726272
Dwarf_Unsigned * dw_index_of_abbrev,
6273-
6274-
/* The number of attr/form pairs, counting the
6275-
trailing 0,0 pair. */
62766273
Dwarf_Unsigned * dw_number_of_attr_form_entries) ;
62776274

62786275
/*! @brief Returns a specific idxattribute form pair.
@@ -6290,7 +6287,7 @@ DW_API int dwarf_dnames_abbrev_by_code(Dwarf_Dnames_Head dw_dn,
62906287
start with 0.
62916288
@param dw_idx_attr
62926289
On success returns the DW_IDX value in the idxattr-form pair.
6293-
@param dw_idx_form
6290+
@param dw_form
62946291
On success returns the DW_FORM value in the idxattr-form pair.
62956292
@param dw_error
62966293
On error returns the usual error details.
@@ -6339,7 +6336,7 @@ DW_API int dwarf_dnames_abbrev_form_by_index(Dwarf_Dnames_Head dw_dn,
63396336
On success returns the entry pool offset of the
63406337
sequence of bytes containing values, such as
63416338
a CU index or a DIE offset.
6342-
@dw_error
6339+
@param dw_error
63436340
The usual error detail record
63446341
@return
63456342
DW_DLV_OK is returned if the specified name
@@ -6407,7 +6404,7 @@ DW_API int dwarf_dnames_entrypool(Dwarf_Dnames_Head dw_dn,
64076404
On success, for a single-cu name table with no
64086405
DW_IDX_compile_unit this is set
64096406
to the CU offset from that single CU-table entry.
6410-
@dw_error
6407+
@param dw_error
64116408
The usual error detail record
64126409
@return
64136410
DW_DLV_OK is returned if the specified name
@@ -6421,7 +6418,7 @@ DW_API int dwarf_dnames_entrypool_values(Dwarf_Dnames_Head dw_dn,
64216418
Dwarf_Unsigned dw_index_of_abbrev,
64226419
Dwarf_Unsigned dw_offset_in_entrypool_of_values,
64236420
Dwarf_Unsigned dw_arrays_length,
6424-
Dwarf_Half *dw_array_dw_idx_number,
6421+
Dwarf_Half *dw_array_idx_number,
64256422
Dwarf_Half *dw_array_form,
64266423
Dwarf_Unsigned *dw_array_of_offsets,
64276424
Dwarf_Sig8 *dw_array_of_signatures,

0 commit comments

Comments
 (0)