aboutsummaryrefslogtreecommitdiff
path: root/bfd/libbfd.h
diff options
context:
space:
mode:
authorTristan Gingold <gingold@adacore.com>2011-09-30 10:39:45 +0000
committerTristan Gingold <gingold@adacore.com>2011-09-30 10:39:45 +0000
commitfc28f9aa231c8f3386e1c9bdb448d9cdd9cae1a9 (patch)
treed1cb8ea7d3d4aea609cdbd1dd1d509b2ecb52b2a /bfd/libbfd.h
parent9852805258de4c870df1f723bf22f21b41ebd6a7 (diff)
downloadgdb-fc28f9aa231c8f3386e1c9bdb448d9cdd9cae1a9.zip
gdb-fc28f9aa231c8f3386e1c9bdb448d9cdd9cae1a9.tar.gz
gdb-fc28f9aa231c8f3386e1c9bdb448d9cdd9cae1a9.tar.bz2
2011-09-30 Tristan Gingold <gingold@adacore.com>
* dwarf2.c (struct dwarf2_debug): Add field debug_sections. (read_section): Add sec argument. Adjust the code to get section names from it. (read_indirect_string): Adjust call to read_section. (read_abbrevs): Ditto. (decode_line_info): Ditto. (read_debug_ranges): Ditto. (DWARF2_DEBUG_INFO, DWARF2_COMPRESSED_DEBUG_INFO): Remove. (find_debug_info): Add debug_sections parameter. Use it instead the above macros. (place_sections): Get section names from stash. (find_line): Add debug_sections argument. Initialize debug_sections field of stash from it. Adjust calls to find_debug_info. (_bfd_dwarf2_find_nearest_line): Add debug_sections argument. Adjust call to find_line. (_bfd_dwarf2_find_line): Adjust call to find_line. * libcoff-in.h (struct dwarf_debug_section): New declaration. (coff_find_nearest_line_with_names): Likewise. * libcoff.h: Regenerate. * libbfd-in.h (struct dwarf_debug_section): Move declaration. (dwarf_debug_sections): Likewise. (_bfd_dwarf2_find_nearest_line): Add debug_sections argument. * libbfd.h: Regenerate. * elf.c (_bfd_elf_find_nearest_line): Adjust call to _bfd_dwarf2_find_nearest_line. * elfxx-mips.c (_bfd_mips_elf_find_nearest_line): Ditto. * elf64-alpha.c (elf64_alpha_find_nearest_line): Ditto. * elf32-arm.c (elf32_arm_find_nearest_line): Ditto. * coffgen.c (coff_find_nearest_line_with_names): New function. (coff_find_nearest_line): Calls coff_find_nearest_line_with_names. * coff-rs6000.c (xcoff_debug_sections): New constant. (xcoff_find_nearest_line): New function. (rs6000coff_vec): Use xcoff_find_nearest_line. (pmac_xcoff_vec): Ditto.
Diffstat (limited to 'bfd/libbfd.h')
-rw-r--r--bfd/libbfd.h26
1 files changed, 13 insertions, 13 deletions
diff --git a/bfd/libbfd.h b/bfd/libbfd.h
index 200a6fa..c2b119d 100644
--- a/bfd/libbfd.h
+++ b/bfd/libbfd.h
@@ -526,10 +526,21 @@ extern bfd_boolean _bfd_dwarf1_find_nearest_line
(bfd *, asection *, asymbol **, bfd_vma, const char **,
const char **, unsigned int *);
+struct dwarf_debug_section
+{
+ const char *uncompressed_name;
+ const char *compressed_name;
+};
+
+/* Map of uncompressed DWARF debug section name to compressed one. It
+ is terminated by NULL uncompressed_name. */
+
+extern const struct dwarf_debug_section dwarf_debug_sections[];
+
/* Find the nearest line using DWARF 2 debugging information. */
extern bfd_boolean _bfd_dwarf2_find_nearest_line
- (bfd *, asection *, asymbol **, bfd_vma, const char **, const char **,
- unsigned int *, unsigned int, void **);
+ (bfd *, const struct dwarf_debug_section *, asection *, asymbol **, bfd_vma,
+ const char **, const char **, unsigned int *, unsigned int, void **);
/* Find the line using DWARF 2 debugging information. */
extern bfd_boolean _bfd_dwarf2_find_line
@@ -816,17 +827,6 @@ extern void bfd_section_already_linked_table_traverse
extern bfd_vma read_unsigned_leb128 (bfd *, bfd_byte *, unsigned int *);
extern bfd_signed_vma read_signed_leb128 (bfd *, bfd_byte *, unsigned int *);
-
-struct dwarf_debug_section
-{
- const char *uncompressed_name;
- const char *compressed_name;
-};
-
-/* Map of uncompressed DWARF debug section name to compressed one. It
- is terminated by NULL uncompressed_name. */
-
-extern const struct dwarf_debug_section dwarf_debug_sections[];
/* Extracted from init.c. */
/* Extracted from libbfd.c. */
bfd_boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int);