This is the mail archive of the gdb-testers@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] DWARF-5: .debug_names index producer


*** TEST RESULTS FOR COMMIT 437afbb81e3a04cbd933fc534a50c686eaa63b19 ***

Author: Jan Kratochvil <jan.kratochvil@redhat.com>
Branch: master
Commit: 437afbb81e3a04cbd933fc534a50c686eaa63b19

DWARF-5: .debug_names index producer

This adds a new "-dwarf-5" switch to "save gdb-index" that makes it
generate index files with DWARF-5 .debug_names/.debug_str sections
instead of GDB's own .gdb_index.

We should probably add a command line option to
contrib/gdb-add-index.sh (incl. cc-with-tweaks.sh) for the new
-dwarf-5 GDB option, and a new target board to make it more convenient
to exercise this.  To be done later.

gdb/ChangeLog
2017-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>
	    Pedro Alves  <palves@redhat.com>

	* contrib/gdb-add-index.sh (index): Rename to ...
	(index4): ... here.
	(index5, debugstr, debugstrmerge, debugstrerr): New variables.
	Support also .debug_names and .debug_str.
	* dwarf2read.c: Include cmath, set, list.
	(INDEX_SUFFIX): Rename to ...
	(INDEX4_SUFFIX): ... here.
	(INDEX5_SUFFIX, DEBUG_STR_SUFFIX): New.
	(file_write(FILE *, const void *, size_t)): New.
	(file_write(FILE *, const std::vector<Elem, Alloc> &)): New.
	(data_buf::append_unsigned_leb128, data_buf::empty): New.
	(data_buf::file_write): Use ::file_write.
	(data_buf::c_str, dwarf5_djb_hash, debug_names)
	(check_dwarf64_offsets): New.
	(psyms_seen_size, write_gdbindex): New from
	write_psymtabs_to_index code.
	(dwarf5_gdb_augmentation, write_debug_names, assert_file_size)
	(enum dw_index_kind): New.
	(write_psymtabs_to_index): New parameter index_kind.  Support
	filename_str and out_file_str.  Move code to write_gdbindex,
	possibly call write_debug_names.
	(save_gdb_index_command): New parameter -dwarf-5.
	(_initialize_dwarf2_read): Document the new parameter -dwarf-5.

gdb/doc/ChangeLog
2017-12-08  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* gdb.texinfo (Index Files): Document .debug_names and -dwarf-5.
--

 gdb/contrib/gdb-add-index.sh |   53 ++
 gdb/doc/gdb.texinfo          |   24 +
 gdb/dwarf2read.c             |  919 ++++++++++++++++++++++++++++++++++++++++--
 3 files changed, 935 insertions(+), 61 deletions(-)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]