22 #define STANDARD_OPERAND_COUNT_DWARF2 9
23 #define STANDARD_OPERAND_COUNT_DWARF3 12
24 #define RZ_BIN_DWARF_INFO 1
27 (((buf) + 1 < buf_end) ? *((ut8 *)(buf)) : 0); \
30 (((buf) + sizeof(ut16) < buf_end) ? rz_read_ble16(buf, big_endian) : 0); \
33 (((buf) + sizeof(ut32) < buf_end) ? rz_read_ble32(buf, big_endian) : 0); \
36 (((buf) + sizeof(ut64) < buf_end) ? rz_read_ble64(buf, big_endian) : 0); \
331 return "DW_AT_lo_user";
333 return "DW_AT_MIPS_linkage_name";
335 return "DW_AT_GNU_call_site_value";
337 return "DW_AT_GNU_call_site_data_value";
339 return "DW_AT_GNU_call_site_target";
341 return "DW_AT_GNU_call_site_target_clobbered";
343 return "DW_AT_GNU_tail_call";
345 return "DW_AT_GNU_all_tail_call_sites";
347 return "DW_AT_GNU_all_call_sites";
349 return "DW_AT_GNU_all_source_call_sites";
351 return "DW_AT_GNU_macros";
353 return "DW_AT_GNU_deleted";
355 return "DW_AT_GNU_dwo_name";
357 return "DW_AT_GNU_dwo_id";
359 return "DW_AT_GNU_ranges_base";
361 return "DW_AT_GNU_addr_base";
363 return "DW_AT_GNU_pubnames";
365 return "DW_AT_GNU_pubtypes";
367 return "DW_AT_hi_user";
482 while (
buf + 1 < buf_end) {
486 if (len < 1 || len >= 0xfff || !
str) {
500 while (
buf + 1 < buf_end) {
503 ut64 id_idx, mod_time, file_len;
511 if (
buf >= buf_end) {
516 if (
buf >= buf_end) {
521 if (
buf >= buf_end) {
526 if (
buf >= buf_end) {
532 entry->id_idx = id_idx;
533 entry->mod_time = mod_time;
534 entry->file_len = file_len;
549 if (file_index >=
header->file_names_count) {
567 const char *include_dir =
NULL;
568 char *own_str =
NULL;
569 if (
file->id_idx > 0 &&
file->id_idx - 1 <
header->include_dirs_count) {
570 include_dir =
header->include_dirs[
file->id_idx - 1];
571 if (include_dir && include_dir[0] !=
'/' && comp_dir) {
572 include_dir = own_str =
rz_str_newf(
"%s/%s/", comp_dir, include_dir);
575 include_dir = comp_dir;
601 if (file_index >=
header->file_names_count) {
605 return header->file_names[file_index].name;
607 if (!cache[file_index]) {
610 return cache[file_index];
615 return opcode -
header->opcode_base;
620 if (!
header->line_range) {
625 return (adj_opcode /
header->line_range) *
header->min_inst_len;
630 if (!
header->line_range) {
635 return header->line_base + (adj_opcode %
header->line_range);
657 if (buf_end -
buf < 8) {
674 if (
buf + 2 > buf_end) {
702 free(
op->args.define_file.filename);
707 bool big_endian,
ut8 target_addr_size) {
715 if (!
buf ||
buf >= buf_end || !op_len || buf_end -
buf < op_len) {
727 addr_size = target_addr_size;
740 op->args.define_file.filename =
fn;
742 if (
buf + 1 < buf_end) {
745 if (
buf &&
buf + 1 < buf_end) {
748 if (
buf &&
buf + 1 < buf_end) {
813 for (
size_t i = 0;
i < args_count;
i++) {
856 switch (
op->opcode) {
867 regs->line +=
op->args.advance_line;
870 regs->file =
op->args.set_file;
873 regs->column =
op->args.set_column;
885 regs->address +=
op->args.fixed_advance_pc;
888 regs->prologue_end = ~0;
891 regs->epilogue_begin = ~0;
894 regs->isa =
op->args.set_isa;
901 switch (
op->opcode) {
911 regs->address =
op->args.set_address;
916 regs->discriminator =
op->args.set_discriminator;
931 regs->discriminator = 0;
952 while (
buf < buf_end) {
1002 const ut8 *buf_start =
buf;
1027 while (
buf <= buf_end) {
1034 size_t bytes_read = 0;
1046 bytes_read =
buf - tmpbuf;
1063 size_t tmp_read = 0;
1081 info, fnc, big_endian, target_addr_size);
1082 bytes_read += tmp_read;
1084 }
while (bytes_read <
buf_size && tmp_read != 0);
1117 const ut8 *buf_end =
buf + obuf_sz;
1126 while (
buf < buf_end) {
1132 size_t header_rest_size = 2 + (is_64bit ? 8 : 4) + 1 + 1;
1133 if (unit_length < header_rest_size || unit_length > buf_end -
buf) {
1136 const ut8 *next_set_buf =
buf + unit_length;
1147 unit_length -= header_rest_size;
1156 if (
pad > unit_length ||
pad > buf_end -
buf) {
1198 if (!
inf->comp_units) {
1202 if (!
inf->line_info_offset_comp_dir) {
1203 goto wurzelbert_comp_units;
1208 wurzelbert_comp_units:
1366 switch (
val->attr_form) {
1411 for (
size_t i = 0;
i <
inf->count;
i++) {
1414 ht_up_free(
inf->line_info_offset_comp_dir);
1415 ht_up_free(
inf->lookup_table);
1428 for (j = 0; j < block->
length; j++) {
1453 const ut8 *debug_str,
size_t debug_str_len,
1457 const ut8 *buf_end =
obuf + obuf_len;
1466 value->string.offset = 0;
1469 switch (
def->attr_form) {
1522 buf +=
value->string.content ? strlen(
value->string.content) + 1 : 1;
1532 if (
value->block.length > 0) {
1534 if (!
value->block.data) {
1537 for (j = 0; j <
value->block.length; j++) {
1550 if (!
buf ||
buf >= buf_end) {
1563 if (debug_str &&
value->string.offset < debug_str_len) {
1564 value->string.content =
1607 if (!
buf ||
buf >= buf_end) {
1705 value->uconstant = 0;
1725 const char *comp_dir =
NULL;
1727 if (abbrev->
count) {
1728 for (
i = 0;
i < abbrev->
count - 1;
i++) {
1732 &die->
attr_values[
i], hdr, debug_str, debug_str_len, big_endian);
1737 comp_dir = attribute->
string.content;
1741 line_info_offset = attribute->
uconstant;
1743 line_info_offset = attribute->
reference;
1752 if (comp_dir && line_info_offset !=
UT64_MAX) {
1755 if (!ht_up_insert(
info->line_info_offset_comp_dir, line_info_offset,
name)) {
1778 size_t first_abbr_idx,
const ut8 *debug_str,
size_t debug_str_len,
bool big_endian) {
1780 const ut8 *
buf = buf_start;
1796 if (abbr_code > abbrevs->
count || !
buf) {
1800 if (
buf >= buf_end) {
1809 ut64 abbr_idx = first_abbr_idx + abbr_code;
1811 if (abbrevs->
count < abbr_idx) {
1881 info->capacity *= 2;
1899 const ut8 *debug_str,
size_t debug_str_len,
bool big_endian) {
1915 while (
buf < buf_end) {
1916 if (
info->count >=
info->capacity) {
1940 RZ_LOG_WARN(
"malformed dwarf have not enough buckets for decls.\n");
1949 if (!abbrev_start) {
1953 size_t first_abbr_idx = abbrev_start - da->
decls;
1988 while (
buf &&
buf + 1 < buf_end) {
2005 if (
buf >= buf_end) {
2015 if (
buf >= buf_end) {
2027 }
while (attr_code && attr_form);
2046 if (strstr(
section->name, sn)) {
2079 size_t debug_str_len = 0;
2085 goto cave_debug_str_buf;
2093 if (!
info->lookup_table) {
2101 for (
i = 0;
i <
info->count;
i++) {
2103 for (j = 0; j < unit->
count; j++) {
2105 ht_up_insert(
info->lookup_table, die->
offset, die);
2112 free(debug_str_buf);
2157 switch (addr_size) {
2182 range->expression = block;
2202 const ut8 *
const buf_start =
buf;
2207 ut64 address_base = 0;
2208 ut64 list_offset = 0;
2212 while (
buf &&
buf < buf_end) {
2216 if (start_addr == 0 && end_addr == 0) {
2218 ht_up_insert(loc_table, loc_list->
offset, loc_list);
2219 list_offset =
buf - buf_start;
2224 }
else if (start_addr == max_offset && end_addr != max_offset) {
2227 address_base = end_addr;
2267 HtUP *loc_table = ht_up_new0();
2286 ht_up_free(loc_table);
RzBinInfo * info(RzBinFile *bf)
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags static arg static fd static protocol static who struct sockaddr static addrlen static backlog struct timeval struct timezone static tz const struct iovec static count static mode const void const struct sockaddr static tolen const char static pathname void static offset struct stat static buf void long static basep static whence static length const void static len static semflg const void static shmflg const struct timespec struct timespec static rem const char static group const void start
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags static arg static fd static protocol static who struct sockaddr static addrlen static backlog struct timeval struct timezone static tz const struct iovec static count static mode const void const struct sockaddr static tolen const char static pathname void static offset struct stat static buf void long static basep static whence static length const void static len key
RZ_API void rz_bin_source_line_info_free(RzBinSourceLineInfo *sli)
RZ_API void rz_bin_source_line_info_builder_init(RzBinSourceLineInfoBuilder *builder)
RZ_API RzBinSourceLineInfo * rz_bin_source_line_info_builder_build_and_fini(RzBinSourceLineInfoBuilder *builder)
RZ_API void rz_bin_source_line_info_builder_push_sample(RzBinSourceLineInfoBuilder *builder, ut64 address, ut32 line, ut32 column, const char *file)
Push a new sample into the builder.
static int init_debug_abbrev(RzBinDwarfDebugAbbrev *da)
static void free_die(RzBinDwarfDie *die)
static void free_attr_value(RzBinDwarfAttrValue *val)
static const ut8 * parse_attr_value(const ut8 *obuf, int obuf_len, RzBinDwarfAttrDef *def, RzBinDwarfAttrValue *value, const RzBinDwarfCompUnitHdr *hdr, const ut8 *debug_str, size_t debug_str_len, bool big_endian)
Parses attribute value based on its definition and stores it into value
RZ_API const char * rz_bin_dwarf_get_attr_name(ut64 attr_code)
RZ_API RzBinDwarfDebugAbbrev * rz_bin_dwarf_parse_abbrev(RzBinFile *binfile)
RZ_API const char * rz_bin_dwarf_get_lang_name(ut64 lang)
RZ_API void rz_bin_dwarf_debug_abbrev_free(RzBinDwarfDebugAbbrev *da)
static RzBinDwarfDebugAbbrev * parse_abbrev_raw(const ut8 *obuf, size_t len)
static const char * dwarf_attr_form_encodings[]
RZ_API st64 rz_bin_dwarf_line_header_get_spec_op_advance_line(const RzBinDwarfLineHeader *header, ut8 opcode)
static ut64 dwarf_read_offset(bool is_64bit, bool big_endian, const ut8 **buf, const ut8 *buf_end)
Reads 64/32 bit unsigned based on format.
static const char * dwarf_tag_name_encodings[]
RZ_API void rz_bin_dwarf_line_header_free_file_cache(const RzBinDwarfLineHeader *hdr, RzBinDwarfLineFileCache fnc)
RZ_API void rz_bin_dwarf_line_info_free(RzBinDwarfLineInfo *li)
static const char * dwarf_attr_encodings[]
RZ_API void rz_bin_dwarf_loc_free(HtUP *loc_table)
static RzBinDwarfLocList * create_loc_list(ut64 offset)
RZ_API void rz_bin_dwarf_line_op_fini(RzBinDwarfLineOp *op)
RZ_API bool rz_bin_dwarf_line_op_run(const RzBinDwarfLineHeader *hdr, RzBinDwarfSMRegisters *regs, RzBinDwarfLineOp *op, RZ_NULLABLE RzBinSourceLineInfoBuilder *bob, RZ_NULLABLE RzBinDwarfDebugInfo *info, RZ_NULLABLE RzBinDwarfLineFileCache fnc)
Execute a single line op on regs and optionally store the resulting line info in bob.
static void free_loc_table_entry(HtUPKv *kv)
RZ_API const char * rz_bin_dwarf_get_attr_form_name(ut64 form_code)
static const ut8 * parse_die(const ut8 *buf, const ut8 *buf_end, RzBinDwarfDebugInfo *info, RzBinDwarfAbbrevDecl *abbrev, RzBinDwarfCompUnitHdr *hdr, RzBinDwarfDie *die, const ut8 *debug_str, size_t debug_str_len, bool big_endian)
static const ut8 * fill_block_data(const ut8 *buf, const ut8 *buf_end, RzBinDwarfBlock *block)
static void free_comp_unit(RzBinDwarfCompUnit *cu)
static RzBinDwarfLineInfo * parse_line_raw(RzBinFile *binfile, const ut8 *obuf, ut64 len, RzBinDwarfLineInfoMask mask, bool big_endian, RZ_NULLABLE RzBinDwarfDebugInfo *info)
RZ_API ut64 rz_bin_dwarf_line_header_get_spec_op_advance_pc(const RzBinDwarfLineHeader *header, ut8 opcode)
static ut64 dwarf_read_address(size_t size, bool big_endian, const ut8 **buf, const ut8 *buf_end)
static const ut8 * parse_ext_opcode(RzBinDwarfLineOp *op, const RzBinDwarfLineHeader *hdr, const ut8 *obuf, size_t len, bool big_endian, ut8 target_addr_size)
static size_t std_opcode_args_count(const RzBinDwarfLineHeader *hdr, ut8 opcode)
static RzBinSection * getsection(RzBinFile *binfile, const char *sn)
static int init_abbrev_decl(RzBinDwarfAbbrevDecl *ad)
static int expand_info(RzBinDwarfDebugInfo *info)
RZ_API void rz_bin_dwarf_line_header_reset_regs(const RzBinDwarfLineHeader *hdr, RzBinDwarfSMRegisters *regs)
static void free_loc_table_list(RzBinDwarfLocList *loc_list)
RZ_API char * rz_bin_dwarf_line_header_get_full_file_path(RZ_NULLABLE const RzBinDwarfDebugInfo *info, const RzBinDwarfLineHeader *header, ut64 file_index)
static const char * dwarf_langs[]
RZ_API const char * rz_bin_dwarf_get_tag_name(ut64 tag)
static const ut8 * parse_line_header(RzBinFile *bf, const ut8 *buf, const ut8 *buf_end, RzBinDwarfLineHeader *hdr, ut64 offset_cur, bool big_endian)
static void free_ht_comp_dir(HtUPKv *kv)
static int expand_cu(RzBinDwarfCompUnit *cu)
RZ_API RzList * rz_bin_dwarf_parse_aranges(RzBinFile *binfile)
static RzBinDwarfDebugInfo * parse_info_raw(RzBinDwarfDebugAbbrev *da, const ut8 *obuf, size_t len, const ut8 *debug_str, size_t debug_str_len, bool big_endian)
Parses whole .debug_info section.
static int abbrev_cmp(const void *a, const void *b)
static int expand_debug_abbrev(RzBinDwarfDebugAbbrev *da)
static size_t parse_opcodes(const ut8 *obuf, size_t len, const RzBinDwarfLineHeader *hdr, RzVector *ops_out, RzBinDwarfSMRegisters *regs, RZ_NULLABLE RzBinSourceLineInfoBuilder *bob, RZ_NULLABLE RzBinDwarfDebugInfo *info, RZ_NULLABLE RzBinDwarfLineFileCache fnc, bool big_endian, ut8 target_addr_size)
RZ_API void rz_bin_dwarf_arange_set_free(RzBinDwarfARangeSet *set)
static bool init_debug_info(RzBinDwarfDebugInfo *inf)
static ut64 get_max_offset(size_t addr_size)
RZ_API RzBinDwarfDebugInfo * rz_bin_dwarf_parse_info(RzBinFile *binfile, RzBinDwarfDebugAbbrev *da)
Parses .debug_info section.
static int expand_abbrev_decl(RzBinDwarfAbbrevDecl *ad)
static const ut8 * info_comp_unit_read_hdr(const ut8 *buf, const ut8 *buf_end, RzBinDwarfCompUnitHdr *hdr, bool big_endian)
Reads all information about compilation unit header.
static void store_line_sample(RzBinSourceLineInfoBuilder *bob, const RzBinDwarfLineHeader *hdr, RzBinDwarfSMRegisters *regs, RZ_NULLABLE RzBinDwarfDebugInfo *info, RZ_NULLABLE RzBinDwarfLineFileCache fnc)
static int init_comp_unit(RzBinDwarfCompUnit *cu)
static const char * get_full_file_path(const RzBinDwarfDebugInfo *info, const RzBinDwarfLineHeader *header, RZ_NULLABLE RzBinDwarfLineFileCache cache, ut64 file_index)
RZ_API const char * rz_bin_dwarf_get_unit_type_name(ut64 unit_type)
static HtUP * parse_loc_raw(HtUP *loc_table, const ut8 *buf, size_t len, size_t addr_size, bool big_endian)
static RzList * parse_aranges_raw(const ut8 *obuf, size_t obuf_sz, bool big_endian)
static RzBinDwarfLocRange * create_loc_range(ut64 start, ut64 end, RzBinDwarfBlock *block)
RZ_API HtUP * rz_bin_dwarf_parse_loc(RzBinFile *binfile, int addr_size)
Parses out the .debug_loc section into a table that maps each list as offset of a list -> LocationLis...
static int init_die(RzBinDwarfDie *die, ut64 abbr_code, ut64 attr_count)
RZ_API RzBinDwarfLineFileCache rz_bin_dwarf_line_header_new_file_cache(const RzBinDwarfLineHeader *hdr)
static void line_unit_free(RzBinDwarfLineUnit *unit)
RZ_API void rz_bin_dwarf_debug_info_free(RzBinDwarfDebugInfo *inf)
static const ut8 * parse_line_header_source(RzBinFile *bf, const ut8 *buf, const ut8 *buf_end, RzBinDwarfLineHeader *hdr)
static void line_header_fini(RzBinDwarfLineHeader *hdr)
static const ut8 * parse_std_opcode(RzBinDwarfLineOp *op, const RzBinDwarfLineHeader *hdr, const ut8 *obuf, size_t len, ut8 opcode, bool big_endian)
static ut64 dwarf_read_initial_length(RZ_OUT bool *is_64bit, bool big_endian, const ut8 **buf, const ut8 *buf_end)
Read an "initial length" value, as specified by dwarf. This also determines whether it is 64bit or 32...
RZ_API ut64 rz_bin_dwarf_line_header_get_adj_opcode(const RzBinDwarfLineHeader *header, ut8 opcode)
static ut8 * get_section_bytes(RzBinFile *binfile, const char *sect_name, size_t *len)
RZ_API RzBinDwarfLineInfo * rz_bin_dwarf_parse_line(RzBinFile *binfile, RZ_NULLABLE RzBinDwarfDebugInfo *info, RzBinDwarfLineInfoMask mask)
static const char * dwarf_unit_types[]
static const ut8 * parse_comp_unit(RzBinDwarfDebugInfo *info, const ut8 *buf_start, RzBinDwarfCompUnit *unit, const RzBinDwarfDebugAbbrev *abbrevs, size_t first_abbr_idx, const ut8 *debug_str, size_t debug_str_len, bool big_endian)
Reads throught comp_unit buffer and parses all its DIEntries.
RZ_API void Ht_() free(HtName_(Ht) *ht)
return memset(p, 0, total)
memcpy(mem, inblock.get(), min(CONTAINING_RECORD(inblock.get(), MEMBLOCK, data) ->size, size))
static void list(RzEgg *egg)
RZ_API RZ_OWN RzList * rz_list_newf(RzListFree f)
Returns a new initialized RzList pointer and sets the free method.
RZ_API RZ_OWN RzList * rz_list_new(void)
Returns a new initialized RzList pointer (free method is not initialized)
RZ_API RZ_BORROW RzListIter * rz_list_push(RZ_NONNULL RzList *list, void *item)
Alias for rz_list_append.
RZ_API RZ_BORROW RzListIter * rz_list_append(RZ_NONNULL RzList *list, void *data)
Appends at the end of the list a new element.
RZ_API void rz_list_free(RZ_NONNULL RzList *list)
Empties the list and frees the list pointer.
void * realloc(void *ptr, size_t size)
void * malloc(size_t size)
void * calloc(size_t number, size_t size)
static const char struct stat static buf struct stat static buf static idle const char static path static fd const char static len const void static prot const char struct module static image struct kernel_sym static table unsigned char static buf static fsuid unsigned struct dirent unsigned static count const struct iovec static count static pid const void static len static flags const struct sched_param static p static pid static policy struct timespec static tp static suid unsigned fn
return strdup("=SP r13\n" "=LR r14\n" "=PC r15\n" "=A0 r0\n" "=A1 r1\n" "=A2 r2\n" "=A3 r3\n" "=ZF zf\n" "=SF nf\n" "=OF vf\n" "=CF cf\n" "=SN or0\n" "gpr lr .32 56 0\n" "gpr pc .32 60 0\n" "gpr cpsr .32 64 0 ____tfiae_________________qvczn\n" "gpr or0 .32 68 0\n" "gpr tf .1 64.5 0 thumb\n" "gpr ef .1 64.9 0 endian\n" "gpr jf .1 64.24 0 java\n" "gpr qf .1 64.27 0 sticky_overflow\n" "gpr vf .1 64.28 0 overflow\n" "gpr cf .1 64.29 0 carry\n" "gpr zf .1 64.30 0 zero\n" "gpr nf .1 64.31 0 negative\n" "gpr itc .4 64.10 0 if_then_count\n" "gpr gef .4 64.16 0 great_or_equal\n" "gpr r0 .32 0 0\n" "gpr r1 .32 4 0\n" "gpr r2 .32 8 0\n" "gpr r3 .32 12 0\n" "gpr r4 .32 16 0\n" "gpr r5 .32 20 0\n" "gpr r6 .32 24 0\n" "gpr r7 .32 28 0\n" "gpr r8 .32 32 0\n" "gpr r9 .32 36 0\n" "gpr r10 .32 40 0\n" "gpr r11 .32 44 0\n" "gpr r12 .32 48 0\n" "gpr r13 .32 52 0\n" "gpr r14 .32 56 0\n" "gpr r15 .32 60 0\n" "gpr r16 .32 64 0\n" "gpr r17 .32 68 0\n")
#define header(is_bt, len_min, ret_op)
static void pad(RzStrBuf *sb, ut32 count)
static void special(struct parse *, int)
#define rz_warn_if_fail(expr)
#define rz_return_if_fail(expr)
#define rz_return_val_if_fail(expr, val)
#define DW_AT_specification
#define DW_AT_binary_scale
#define DW_AT_picture_string
#define DW_AT_call_data_value
#define DW_TAG_access_declaration
#define DW_TAG_catch_block
#define DW_TAG_thrown_type
#define DW_AT_data_location
#define DW_AT_threads_scaled
#define DW_LNE_set_address
#define DW_TAG_subrange_type
#define DW_TAG_ptr_to_member_type
#define DW_LNS_set_column
#define DW_TAG_subprogram
#define DW_AT_GNU_pubtypes
#define DW_LNS_advance_pc
#define DW_AT_GNU_all_call_sites
#define DW_TAG_volatile_type
#define DW_AT_data_member_location
#define DW_TAG_interface_type
#define DW_AT_calling_convention
#define DW_TAG_inlined_subroutine
#define DW_FORM_ref_udata
#define DW_LNS_advance_line
@ RZ_BIN_DWARF_LINE_INFO_MASK_OPS
@ RZ_BIN_DWARF_LINE_INFO_MASK_LINES
#define DW_AT_GNU_call_site_target_clobbered
#define DW_TAG_partial_unit
#define DW_AT_default_value
#define DW_TAG_variant_part
#define DW_TAG_formal_parameter
#define COMP_UNIT_CAPACITY
#define DW_AT_discr_value
#define DW_AT_loclists_base
#define DW_AT_GNU_all_source_call_sites
#define DW_TAG_imported_unit
#define DW_AT_GNU_deleted
#define DW_TAG_class_type
#define DW_AT_description
#define DW_TAG_unspecified_type
#define DW_AT_call_all_tail_calls
#define DW_TAG_template_type_param
#define DW_AT_export_symbols
#define DW_TAG_inheritance
#define DW_AT_call_parameter
#define DW_AT_byte_stride
#define DW_TAG_structure_type
#define DW_LANG_C_plus_plus
#define DW_LNS_negate_stmt
#define DW_AT_decl_column
#define DW_TAG_template_alias
#define DW_AT_call_data_location
#define DW_AT_upper_bound
#define DW_TAG_array_type
#define DW_AT_GNU_call_site_data_value
#define DWARF_INIT_LEN_64
#define DW_AT_accessibility
#define DW_AT_digit_count
#define DW_TAG_shared_type
#define DW_TAG_mutable_type
#define DW_AT_GNU_addr_base
#define DW_AT_data_bit_offset
#define DW_AT_decimal_scale
#define DW_TAG_pointer_type
#define DW_AT_call_all_source_calls
#define DW_AT_rnglists_base
#define DW_FORM_implicit_const
#define DW_AT_call_tail_call
#define DW_AT_vtable_elem_location
#define DW_AT_MIPS_linkage_name
#define DW_LANG_Fortran03
#define DW_AT_decimal_sign
#define DW_AT_abstract_origin
#define DW_AT_call_origin
#define DW_TAG_null_entry
#define DW_AT_containing_type
#define DW_LNE_set_discriminator
#define DW_TAG_subroutine_type
#define DW_TAG_const_type
#define DW_AT_use_location
#define DW_AT_GNU_call_site_value
#define DW_LANG_C_plus_plus_14
#define DW_AT_declaration
#define DW_TAG_compile_unit
#define DW_AT_start_scope
#define DW_AT_string_length_byte_size
#define DW_LANG_Fortran08
#define DW_TAG_unspecified_parameters
#define DW_AT_call_column
#define DW_LANG_ObjC_plus_plus
#define DW_TAG_common_inclusion
#define DW_LNS_set_epilogue_begin
@ RZ_BIN_DWARF_LINE_OP_TYPE_SPEC
@ RZ_BIN_DWARF_LINE_OP_TYPE_EXT
@ RZ_BIN_DWARF_LINE_OP_TYPE_STD
char ** RzBinDwarfLineFileCache
Opaque cache for fully resolved filenames during Dwarf Line Info Generation This cache stores full fi...
#define DW_LNS_fixed_advance_pc
#define DW_TAG_dwarf_procedure
#define DW_AT_rvalue_reference
#define DW_TAG_restrict_type
#define DW_FORM_flag_present
#define DW_LNE_define_file
#define DW_LANG_Fortran77
#define DW_AT_call_all_calls
#define DW_AT_call_return_pc
#define DW_LNS_set_basic_block
#define DW_TAG_entry_point
#define DW_AT_address_class
#define DW_TAG_string_type
#define DW_AT_static_link
#define DW_AT_const_value
#define DW_TAG_enumeration_type
#define DW_TAG_imported_declaration
#define DW_TAG_imported_module
#define DW_TAG_rvalue_reference_type
#define DW_TAG_enumerator
#define DW_AT_object_pointer
#define DW_AT_common_reference
#define DW_AT_str_offsets_base
#define DW_AT_string_length
#define DW_AT_GNU_ranges_base
#define DW_AT_stride_size
#define DW_TAG_reference_type
#define DW_AT_lower_bound
#define DW_TAG_template_value_param
#define DW_TAG_union_type
#define DW_AT_call_target
#define DW_LANG_Fortran95
#define DW_AT_variable_parameter
#define DW_UT_split_compile
#define DW_AT_linkage_name
#define DW_AT_namelist_item
#define DW_AT_call_target_clobbered
#define DW_AT_main_subprogram
#define DW_LNS_set_prologue_end
#define DW_AT_GNU_dwo_name
#define DW_LNE_end_sequence
#define DW_FORM_sec_offset
#define DW_AT_is_optional
#define DW_AT_GNU_pubnames
#define DW_AT_GNU_tail_call
#define DEBUG_INFO_CAPACITY
#define DW_LANG_Fortran90
#define DW_AT_GNU_call_site_target
#define DW_LNS_const_add_pc
#define DW_TAG_packed_type
#define DW_TAG_namelist_item
#define DW_AT_GNU_all_tail_call_sites
#define DW_TAG_lexical_block
#define DW_AT_string_length_bit_size
#define DW_TAG_common_block
#define DW_AT_return_addr
#define DW_AT_identifier_case
RZ_API st64 rz_buf_read_at(RZ_NONNULL RzBuffer *b, ut64 addr, RZ_NONNULL RZ_OUT ut8 *buf, ut64 len)
Read len bytes of the buffer at the specified address.
void(* RzListFree)(void *ptr)
#define RZ_LOG_WARN(fmtstr,...)
#define RZ_LOG_ERROR(fmtstr,...)
static ut64 rz_num_align_delta(ut64 v, ut64 alignment)
Padding to align v to the next alignment-boundary.
RZ_API char * rz_str_newf(const char *fmt,...) RZ_PRINTF_CHECK(1
RZ_API char * rz_str_ndup(RZ_NULLABLE const char *ptr, int len)
Create new copy of string ptr limited to size len.
RZ_API size_t rz_str_nlen(const char *s, size_t n)
RZ_API const ut8 * rz_uleb128(const ut8 *data, int datalen, RZ_NULLABLE ut64 *v, const char **error)
RZ_API const ut8 * rz_leb128(const ut8 *data, int datalen, st64 *v)
RZ_API void * rz_vector_flush(RzVector *vec)
Turn the vector into a fixed-size array. This will clear the vector and return an array of its origin...
RZ_API void rz_pvector_init(RzPVector *vec, RzPVectorFree free)
RZ_API void rz_pvector_fini(RzPVector *vec)
static size_t rz_pvector_len(const RzPVector *vec)
RZ_API void * rz_vector_push(RzVector *vec, void *x)
static void ** rz_pvector_push(RzPVector *vec, void *x)
RZ_API void rz_vector_fini(RzVector *vec)
static void ** rz_pvector_flush(RzPVector *vec)
static size_t rz_vector_len(const RzVector *vec)
RZ_API void rz_vector_init(RzVector *vec, size_t elem_size, RzVectorFree free, void *free_user)
RzBinDwarfCompUnitHdr hdr
RzBinDwarfAbbrevDecl * decls
RzBinDwarfAttrValue * attr_values
Line info of all compilation units from the entire debug_line section.
struct rz_bin_source_line_info_t * lines
DWARF 3 Standard Section 6.2 Line Number Information This contains the entire raw line info for one c...
RzBinDwarfLineHeader header
struct dwarf_attr_kind::@251::@253 string
DWARF 3 Standard Section 6.1.2 Lookup by Address.
RzBinDwarfARange * aranges
XX curplugin == o->plugin.
ut64(WINAPI *w32_GetEnabledXStateFeatures)()
static unsigned char * obuf
int inf(FILE *source, FILE *dest)
int def(FILE *source, FILE *dest, int level)