Main index | Section 3 | Options |
#include <libdwarf.h>
Function dwarf_next_cu_header_c() is the API recommended for new application code. Function dwarf_next_cu_header() and dwarf_next_cu_header_b() can only operate on compilation units associated with the "amp;.debug_info" section. They are less general than function dwarf_next_cu_header_c(), and are deprecated for use by new application code.
Argument dbg should reference a DWARF debug context allocated using dwarf_init(3). If argument is_info is set to 1, the function returns information for compilation units found in the "amp;.debug_info" section. If argument is_info is set to 0, the function returns information for type units found in the "amp;.debug_types" sections. Argument cu_length should point to a location that will be set to the length of the compilation or type unit. Argument cu_version should point to a location that will be set to the version number for the compilation or type unit. Argument cu_abbrev_offset should point to a location that will be set to the starting offset (in the ".debug_abbrev" section) of the set of debugging information entry abbreviations associated with this compilation or type unit. Argument cu_pointer_size should point to a location that will be set to the size in bytes of an address for the machine architecture of the underlying object being debugged. Argument cu_offset_size should point to a location that will be set to the size in bytes for a DWARF offset in the compilation or type unit. Argument cu_extension_size is only needed for processing MIPS/IRIX objects that use a non-standard DWARF format. It should point to a location that will be set to 4 for normal objects and to 0 for non-standard ones. Argument type_signature and type_offset is only needed for processing type units. Argument type_signature should point to a location that will be set to the 64-bit unique signature of the type described in the type unit. Argument type_offset should point to a location that will be set to the offset of the debugging information entry that describes the type. Argument cu_next_offset should point to a location that will be set to the offset of the next compilation unit header in the "amp;.debug_info" section, or the offset of the next type unit header in the "amp;.debug_types" section. Argument err should point to a location that will hold an error descriptor in case of an error.
Function dwarf_next_cu_header_b() is identical to function dwarf_next_cu_header_c() except that it does not provide arguments is_info, type_signature and type_offset.
Function dwarf_next_cu_header() is identical to function dwarf_next_cu_header_b() except that it does not provide arguments cu_offset_size and cu_extension_size.
A value of NULL may be used for any of the arguments cu_length, cu_version, cu_abbrev_offset, cu_pointer_size, cu_offset_size, cu_extension_size, type_signature, type_offset, cu_next_offset and err if the caller is not interested in the respective value.
If the debug object contains multiple "amp;.debug_types" sections, the function dwarf_next_types_section() can be called to move the internal pointer to the next "amp;.debug_types" section. As a result, subsequent calls of the function dwarf_next_cu_header_c() will operate on the new "amp;.debug_types" section. Function dwarf_next_types_section() returns DW_DLV_NO_ENTRY when there are no more "amp;.debug_types" sections left in the debug object.
[DW_DLE_ARGUMENT] | Argument dbg was NULL. |
DWARF_NEXT_CU_HEADER (3) | December 21, 2014 |
Main index | Section 3 | Options |
Please direct any comments about this manual page service to Ben Bullock. Privacy policy.
“ | A UNIX saleslady, Lenore, Enjoys work, but she likes the beach more. She found a good way To combine work and play: She sells C shells by the seashore. |
” |