Lines Matching refs:symbols
191 void symbols__fixup_duplicate(struct rb_root_cached *symbols)
199 nd = rb_first_cached(symbols);
216 rb_erase_cached(&next->rb_node, symbols);
223 rb_erase_cached(&curr->rb_node, symbols);
229 /* Update zero-sized symbols using the address of the next symbol */
230 void symbols__fixup_end(struct rb_root_cached *symbols, bool is_kallsyms)
232 struct rb_node *nd, *prevnd = rb_first_cached(symbols);
252 * In kallsyms, it determines module symbols using '[' character
288 * We still haven't the actual symbols, so guess the
338 void symbols__delete(struct rb_root_cached *symbols)
341 struct rb_node *next = rb_first_cached(symbols);
346 rb_erase_cached(&pos->rb_node, symbols);
351 void __symbols__insert(struct rb_root_cached *symbols,
354 struct rb_node **p = &symbols->rb_root.rb_node;
382 rb_insert_color_cached(&sym->rb_node, symbols, leftmost);
385 void symbols__insert(struct rb_root_cached *symbols, struct symbol *sym)
387 __symbols__insert(symbols, sym, false);
390 static struct symbol *symbols__find(struct rb_root_cached *symbols, u64 ip)
394 if (symbols == NULL)
397 n = symbols->rb_root.rb_node;
413 static struct symbol *symbols__first(struct rb_root_cached *symbols)
415 struct rb_node *n = rb_first_cached(symbols);
423 static struct symbol *symbols__last(struct rb_root_cached *symbols)
425 struct rb_node *n = rb_last(&symbols->rb_root);
491 static struct symbol *symbols__find_by_name(struct symbol *symbols[],
510 cmp = symbol__match_symbol_name(symbols[i]->name, name, includes);
519 s = symbols[i];
526 struct symbol *tmp = symbols[i - 1];
536 assert(!found_idx || !s || s == symbols[*found_idx]);
548 __symbols__insert(&dso->symbols, sym, dso->kernel);
560 rb_erase_cached(&sym->rb_node, &dso->symbols);
569 dso->last_find_result.symbol = symbols__find(&dso->symbols, addr);
577 return symbols__find(&dso->symbols, addr);
582 return symbols__first(&dso->symbols);
587 return symbols__last(&dso->symbols);
623 dso->symbol_names = symbols__sort_by_name(&dso->symbols, &len);
709 * These are symbols in the kernel image, so make sure that
755 struct rb_root_cached *root = &dso->symbols;
760 /* Ignore local symbols for ARM modules */
765 * module symbols are not sorted so we add all
766 * symbols, setting length to 0, and rely on
773 * We will pass the symbols to the filter later, in
796 struct rb_root_cached old_root = dso->symbols;
797 struct rb_root_cached *root = &dso->symbols;
830 symbols__insert(&curr_map_dso->symbols, pos);
841 * Split the symbols into maps, making sure there are no overlaps, i.e. the
852 struct rb_root_cached *root = &dso->symbols;
884 * We assume all symbols of a module are
887 * symbols are in its kmap. Mark it as
915 * These symbols are not needed anymore since the
917 * symbols instead. Avoid having to deal with
920 * symbols at this point.
976 symbols__insert(&curr_map_dso->symbols, pos);
1506 * If one of the corresponding symbols is there, assume the
1583 symbols__fixup_end(&dso->symbols, true);
1584 symbols__fixup_duplicate(&dso->symbols);
1645 symbols__insert(&dso->symbols, sym);
1690 asymbol **symbols, *sym;
1717 symbols = malloc(symbols_size);
1718 if (!symbols)
1721 symbols_count = bfd_canonicalize_symtab(abfd, symbols);
1728 if (!strcmp(bfd_asymbol_name(symbols[i]), "__ImageBase") ||
1729 !strcmp(bfd_asymbol_name(symbols[i]), "__image_base__"))
1733 /* PE symbols can only have 4 bytes, so use .text high bits */
1735 dso->text_offset += (u32)bfd_asymbol_value(symbols[i]);
1741 qsort(symbols, symbols_count, sizeof(asymbol *), bfd_symbols__cmpvalue);
1747 sym = symbols[i];
1753 bfd_asymbol_section(symbols[i + 1]) == section &&
1754 bfd2elf_binding(symbols[i + 1]) < 0)
1758 bfd_asymbol_section(symbols[i + 1]) == section)
1759 len = symbols[i + 1]->value - sym->value;
1769 symbols__insert(&dso->symbols, symbol);
1775 symbols__fixup_end(&dso->symbols, false);
1776 symbols__fixup_duplicate(&dso->symbols);
1781 free(symbols);
2222 pr_debug("Using %s for symbols\n", symfs_vmlinux);
2422 pr_debug("Using %s for symbols\n", kallsyms_filename);
2467 pr_debug("Using %s for symbols\n", kallsyms_filename);
2713 * A path to symbols of "/" is identical to ""