+2022-09-14 Rupesh Potharla <Rupesh.Potharla@amd.com>
+
+ * testsuite/binutils-all/readelf.exp (readelf_wi_test): Extend
+ regexps to allow for output genreated by the Clang compiler.
+
+2022-09-12 Aaron Merey <amerey@redhat.com>
+
+ * objcopy.c (might_need_separate_debug_info): Add with_source_code to
+ the options that cause this function to return true.
+ (main.c): Add with_source_code to the options that enable
+ dump_any_debugging.
+
+2022-09-09 Nick Clifton <nickc@redhat.com>
+
+ PR 29532
+ * objcopy.c (setup_section): Leave group sections intact when
+ creating separate debuginfo files.
+
+2022-09-08 Nick Clifton <nickc@redhat.com>
+
+ PR 29523
+ * dwarf.c (display_debug_lines_decoded): Correctly handle DWARF-5
+ directory and filename tables.
+
+2022-09-02 Aaron Merey <amerey@redhat.com>
+
+ PR 29075
+ * objdump.c (find_separate_debug): New function. Finds the bfd
+ corresponding to the separate debuginfod of a given bfd.
+ (find_alt_debug): New function. Finds the bfd corresponding to the
+ .gnu_debugaltlink of a given bfd.
+ (slurp_file): Add bfd parameter. If a source file cannot be found
+ attempt to download it from debuginfod, if enabled.
+ (try_print_file_open): Add bfd parameter and pass it to slurp_file.
+ (show_line): If debuginfod is enabled, call
+ bfd_find_nearest_line_with_alt instead of bfd_find_nearest_line.
+
+2022-09-01 Nick Clifton <nickc@redhat.com>
+
+ PR 29534
+ * dllwrap.c: Replace uses of choose_temp_base() with
+ make_temp_file().
+ * dlltool.c: Likewise.
+ * resrc.c: Likewise.
+
+2022-08-23 Nick Clifton <nickc@redhat.com>
+
+ PR 29489
+ * dlltool.c (deterministic): New variable.
+ (gen_lib_file): If deterministic is true set the
+ BFD_DETERMINISTIC_OUTPUT flag.
+ (usage): Mention --deterministic-libraries and
+ --non-deterministic-libraries.
+ (long_options): Add new options.
+ (main): Parse new options.
+ * doc/binutils.texi: Document the new options.
+ * NEWS: Mention the new feature.
+
+2022-08-22 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (check_magic_number): New function. Checks the magic
+ bytes at the start of a file. If they are not the ELF format
+ magic values, then attempts to generate a helpful error message.
+ (process_file_header): Call check_magic_number.
+
+2022-08-09 Nick Clifton <nickc@redhat.com>
+
+ PR 29457
+ * objdump.c (disassembler_color): Change type to an enum.
+ (disassembler_extended_color): Remove.
+ (usage): Update.
+ (objdump_color_for_assembler_style): Update.
+ (main): Update initialisation of disassembler_color. If not
+ initialised via a command line option, set based upon terminal
+ output.
+ * doc/binutils.texi: Update description of disassmbler-color
+ option.
+ * testsuite/binutils-all/arc/objdump.exp: Add
+ --disassembler-color=off option when disassembling.
+ * testsuite/binutils-all/arm/objdump.exp: Likewise.
+
+2022-08-08 Nick Clifton <nickc@redhat.com>
+
+ * README-how-to-make-a-release: Add a link to the NEWS files in
+ the release announcement email.
+
+2022-07-08 Nick Clifton <nickc@redhat.com>
+
+ * 2.39 branch created.
+
+2022-07-01 Nick Clifton <nickc@redhat.com>
+
+ * dwarf.c (display_debug_rnglists): Add newline at end of listing.
+
+2022-06-30 Nick Clifton <nickc@redhat.com>
+
+ * dwarf.c (dwarf_select_sections_by_name): If the entry's value is
+ zero then clear the corresponding variable.
+ (dwarf_select_sections_by_letters): Likewise.
+ * testsuite/binutils-all/debuginfo.exp: Expect -WE and -wE
+ debuginfod tests to fail.
+
+2022-06-28 Nick Clifton <nickc@redhat.com>
+
+ PR 29267
+ * dwarf.c (display_debug_rnglists): New function, broken out of..
+ (display_debug_ranges): ... here.
+ (read_and_display_attr_value): Correct calculation of index
+ displayed for DW_FORM_loclistx and DW_FORM_rnglistx.
+ * testsuite/binutils-all/x86-64/pr26808.dump: Update expected
+ output.
+
+2022-06-27 Nick Clifton <nickc@redhat.com>
+
+ PR 29289
+ * dwarf.c (display_debug_names): Replace assert with a warning
+ message.
+
+2022-06-27 Nick Clifton <nickc@redhat.com>
+
+ PR 29290
+ * dwarf.c (read_and_display_attr_value): Check that debug_info_p
+ is set before dereferencing it.
+
+2022-06-27 Nick Clifton <nickc@redhat.com>
+
+ * dwarf.c (fetch_indexed_string): Do not use length of first table
+ in string section as the length of every table in the section.
+
+ * testsuite/binutils-all/pr26112.r: Update expected output.
+
+2022-06-22 Kumar N, Bhuvanendra <Kavitha.Natarajan@amd.com>
+
+ * dwarf.c (fetch_indexed_string): Added new parameter
+ str_offsets_base to calculate the string offset.
+ (read_and_display_attr_value): Read DW_AT_str_offsets_base
+ attribute.
+ (process_debug_info): While allocating memory and initializing
+ debug_information, do it for do_debug_info also, if its true.
+ (load_separate_debug_files): Load .debug_str_offsets if exists.
+ * dwarf.h (struct debug_info): Add str_offsets_base field.
+
+2022-06-22 Marcus Nilsson <brainbomb@gmail.com>
+
+ * readelf.c: (slurp_relr_relocs) Use malloc instead of xmalloc
+ when allocating space for relocations.
+
+2022-06-21 Kumar N, Bhuvanendra <Kavitha.Natarajan@amd.com>
+
+ * dwarf.h (struct debug_info): Add rnglists_base field.
+ * dwarf.c (read_and_display_attr_value): Read attribute DW_AT_rnglists_base.
+ (display_debug_rnglists_list): While handling DW_RLE_base_addressx,
+ DW_RLE_startx_endx, DW_RLE_startx_length items, pass the proper parameter
+ value to fetch_indexed_addr(), i.e. fetch the proper entry in .debug_addr section.
+ (display_debug_ranges): Add rnglists_base to the .debug_rnglists base address.
+ (load_separate_debug_files): Load .debug_addr section, if exists.
+
+2022-05-20 Nick Clifton <nickc@redhat.com>
+
+ * dwarf.c (dwarf_select_sections_by_names): Return zero if no
+ sections were selected.
+ (dwarf_select_sections_by_letters): Likewise.
+ * dwarf.h: (dwarf_select_sections_by_names): Update prototype.
+ (dwarf_select_sections_by_letters): Update prototype.
+ * objdump.c (might_need_separate_debug_info): New function.
+ (dump_bfd): Call new function before attempting to load separate
+ debug info files.
+ (main): Do not enable dwarf section dumping for -WK or -WN.
+ * readelf.c (parse_args): Do not enable dwarf section dumping for
+ -wK or -wN.
+ (might_need_separate_debug_info): New function.
+ (process_object): Call new function before attempting to load
+ separate debug info files.
+ * testsuite/binutils-all/debuginfo.exp: Expect -WE and -wE
+ debuginfod tests to pass.
+ * testsuite/binutils-all/objdump.Wk: Add extra regexps.
+ * testsuite/binutils-all/readelf.k: Add extra regexps.
+
+2022-05-19 Nick Clifton <nickc@redhat.com>
+
+ * dlltool.c (run): Initialise errmsg_fmt.
+ * dllwrap.c (run): Likewise.
+ * resrc.c (run_cmd): Likewise.
+ * mclex.c (mc_add_keyword): Initialise usz.
+ * srconv.c (wd_hd): Initialise hd.spare2.
+ * windmc.c (mc_add_node_lang): Initialise s.
+ (mc_generate_bin_item): Initialise cvt_txt.
+ (main): Initialise u.
+
+2022-05-18 Nick Clifton <nickc@redhat.com>
+
+ PR 29135
+ * nm.c (non_weak): New variable.
+ (filter_symbols): When non-weak is true, ignore weak symbols.
+ (long_options): Add --no-weak.
+ (usage): Mention --no-weak.
+ (main): Handle -W/--no-weak.
+ * doc/binutils.texi: Document new feature.
+ * NEWS: Mention the new feature.
+ * testsuite/binutils-all/nm.exp: Add test of new feature.
+ * testsuite/binutils-all/no-weak.s: New test source file.
+
+2022-04-25 Nick Clifton <nickc@redhat.com>
+
+ PR 29072
+ * testsuite/lib/binutils-common.exp (prune_warnings_extra): Filter
+ out notes about the executable stacjk behaviour beign deprecated.
+
+2022-04-12 Nick Clifton <nickc@redhat.com>
+
+ PR 28992
+ * objcopy.c (is_strip_section_1): Do not delete debuglink sections
+ when stripping debug information.
+
+2022-04-06 Nick Clifton <nickc@redhat.com>
+
+ PR 28981
+ * dwarf.c (fetch_indexed_value): Rename to fecth_indexed_addr and
+ return the address, rather than a string.
+ (fetch_indexed_value): New function - returns a value indexed by a
+ DW_FORM_loclistx or DW_FORM_rnglistx form.
+ (read_and_display_attr_value): Add support for DW_FORM_loclistx
+ and DW_FORM_rnglistx.
+ (process_debug_info): Load the loclists and rnglists sections.
+ (display_loclists_list): Add support for DW_LLE_base_addressx,
+ DW_LLE_startx_endx, DW_LLE_startx_length and
+ DW_LLE_default_location.
+ (display_offset_entry_loclists): New function. Displays a
+ .debug_loclists section that contains offset entry tables.
+ (display_debug_loc): Call the new function.
+ (display_debug_rnglists_list): Add support for
+ DW_RLE_base_addressx, DW_RLE_startx_endx and DW_RLE_startx_length.
+ (display_debug_ranges): Display the contents of the section's
+ header.
+ * dwarf.h (struct debug_info): Add loclists_base field.
+ * testsuite/binutils-all/dw5.W: Update expected output.
+ * testsuite/binutils-all/x86-64/pr26808.dump: Likewise.
+
+2022-04-01 John Baldwin <jhb@FreeBSD.org>
+
+ * readelf.c (get_freebsd_elfcore_note_type): Handle
+ NT_FREEBSD_X86_SEGBASES.
+
+2022-03-31 Nick Clifton <nickc@redhat.com>
+
+ * arlex.l: Accept the plus character as part of a filename.
+
+2022-03-16 Fangrui Song <maskray@google.com>
+
+ PR binutils/28926
+ * objcopy.c (filter_symbols): Apply weaken to STB_GNU_UNIQUE symbols
+ * NEWS: Mention feature.
+ * testsuite/binutils-all/objcopy.exp (objcopy_test_symbol_manipulation): New test.
+ * testsuite/binutils-all/weaken-gnu-unique.s: New.
+
+2022-03-16 Martin Storsjö <martin@martin.st>
+
+ PR 28885
+ * dlltool.c (main): use imp_name rather than dll_name when
+ generating a temporary file name.
+
+2022-03-16 Simon Marchi <simon.marchi@efficios.com>
+
+ * readelf.c (dump_relocations): Handle EM_AMDGPU.
+
+2022-03-16 Simon Marchi <simon.marchi@efficios.com>
+
+ * Makefile.am (readelf_CFLAGS): New.
+ (readelf_LDADD): Add MSGPACK_LIBS.
+ * Makefile.in: Re-generate.
+ * config.in: Re-generate.
+ * configure: Re-generate.
+ * configure.ac: Add --with-msgpack flag and check for msgpack
+ using pkg-config.
+ * readelf.c: Include msgpack.h if HAVE_MSGPACK.
+ (print_note_contents_hex): New.
+ (print_indents): New.
+ (dump_msgpack_obj): New.
+ (dump_msgpack): New.
+ (print_amdgpu_note): New.
+ (process_note): Handle NT_AMDGPU_METADATA note contents.
+ Use print_note_contents_hex.
+
+2022-03-16 Simon Marchi <simon.marchi@efficios.com>
+
+ * readelf.c (get_amdgpu_elf_note_type): New.
+ (process_note): Handle "AMDGPU" notes.
+
+2022-03-16 Simon Marchi <simon.marchi@efficios.com>
+
+ * readelf.c: Include elf/amdgcn.h.
+ (decode_AMDGPU_machine_flags): New.
+ (get_machine_flags): Handle flags for EM_AMDGPU machine type.
+
+2022-03-16 Simon Marchi <simon.marchi@efficios.com>
+
+ * readelf.c (get_osabi_name): Handle EM_AMDGPU OS ABIs.
+
+2022-03-16 Nick Clifton <nickc@redhat.com>
+
+ * po/sr.po: Updated Serbian translation.
+
+2022-03-15 Tom Tromey <tromey@adacore.com>
+
+ * dwarf-mode.el: Now 1.7.
+ (dwarf--sentinel): Switch to the process buffer.
+
+2022-03-11 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
+
+ * MAINTAINERS: Add gprofng maintainer.
+ * README-how-to-make-a-release: Add gprofng.
+
+2022-03-10 Nick Clifton <nickc@redhat.com>
+
+ * dwarf.c (use_debuginfod): New variable. Set to 1.
+ (load_separate_debug_info): Only call
+ debuginfod_fetch_separate_debug_info is use_debuginfod is true.
+ (dwarf_select_sections_by_names): Add do-not-use-debuginfod and
+ use-debuginfod options.
+ (dwarf_select_sections_by_letters): Add D and E options.
+ * dwarf.h (use_debuginfod): New extern.
+ * objdump.c (usage): Mention the new options.
+ * readelf.c (usage): Likewise.
+ * doc/binutils.texi: Document the new options.
+ * doc/debug-options.texi: Describe the new options.
+ * NEWS: Mention the new feature.
+ * testsuite/binutils-all/debuginfod.exp: Add tests of the new
+ options.
+
+2021-03-06 Maciej W. Rozycki <macro@orcam.me.uk>
+
+ * testsuite/binutils-all/mips/mips1-branch-alias.d: New test.
+ * testsuite/binutils-all/mips/mips1-branch-noalias.d: New test.
+ * testsuite/binutils-all/mips/mips2-branch-alias.d: New test.
+ * testsuite/binutils-all/mips/mips2-branch-noalias.d: New test.
+ * testsuite/binutils-all/mips/mips32r6-branch-alias.d: New test.
+ * testsuite/binutils-all/mips/mips32r6-branch-noalias.d: New
+ test.
+ * testsuite/binutils-all/mips/micromips-branch-alias.d: New
+ test.
+ * testsuite/binutils-all/mips/micromips-branch-noalias.d: New
+ test.
+ * testsuite/binutils-all/mips/mips-branch-alias.s: New test
+ source.
+ * testsuite/binutils-all/mips/micromips-branch-alias.s: New test
+ source.
+ * testsuite/binutils-all/mips/mips.exp: Run the new tests.
+
+2022-03-04 Simon Marchi <simon.marchi@polymtl.ca>
+
+ * readelf.c (process_dynamic_section): Fix indentation.
+
+2022-02-09 Nick Clifton <nickc@redhat.com>
+
+ * README-how-to-make-a-release: Update after the 2.38 release.
+
+2022-01-27 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2022-01-24 Nick Clifton <nickc@redhat.com>
+
+ * po/bg.po: Updated Bulgarian translation.
+ * po/fr.po: Updated French translation.
+ * po/ro.po: Updated Romanian translation.
+ * po/uk.po: Updated Ukranian translation.
+
+2022-01-22 Martin Storsjö <martin@martin.st>
+
+ * dlltool.c (main): Allow inferring tmp_prefix from the dll name
+ from a def file.
+
+2022-01-22 Nick Clifton <nickc@redhat.com>
+
+ * configure: Regenerate.
+ * po/binutils.pot: Regenerate.
+
+2022-01-22 Nick Clifton <nickc@redhat.com>
+
+ * 2.38 release branch created.
+
+2022-01-17 Nick Clifton <nickc@redhat.com>
+
+ * Makefile.in: Regenerate.
+
+2022-01-11 Fangrui Song <maskray@google.com>
+
+ PR binutils/28759
+ * ar.c (long_options): Add --thin.
+ (usage) Add --thin. Deprecate -T without diagnostics.
+ * doc/binutils.texi: Add doc.
+ * NEWS: Mention --thin.
+ * binutils/testsuite/binutils-all/ar.exp: Add tests.
+
+2022-01-11 Martin Storsjö <martin@martin.st>
+
+ * dlltool.c (main): If a prefix has not been provided, attempt to
+ use a deterministic one based upon the dll name.
+
+2022-01-07 Pavel Mayorov <pmayorov@cloudlinux.com>
+
+ PR 28718
+ * dwarf.c: Revert previous delta.
+ (debug_get_real_type): Reject indirect types that point to
+ indirect types.
+ (debug_get_type_name, debug_get_type_size, debug_write_type):
+ Likewise.
+
+2022-01-06 Nick Clifton <nickc@redhat.com>
+
+ * debug.c (debug_write_type): Allow for malicious recursion via
+ indirect debug types.
+
+2022-01-04 Nick Clifton <nickc@redhat.com>
+
+ PR 28716
+ * dwarf.c (load_build_id_debug_file): Remove spurious printf.
+
+2021-12-16 Nick Clifton <nickc@redhat.com>
+
+ PR 28697
+ * dwarf.c (load_build_id_debug_file): New function.
+ (try_build_id_prefix): New function.
+ (check_for_and_load_links): Call load_build_id_debug_file.
+ (debug_displays): Add entry for .note.gnu.build-id.
+ * dwarf.h (enum dwarf_section_display_enum): Add
+ note_gnu_build_id.
+ * testsuite/binutils-all/debuginfod.exp (test_fetch_debuglink):
+ Fix regexp for loads via debuglink section.
+
+2021-12-03 Chenghua Xu <xuchenghua@loongson.cn>
+
+ * MAINTAINERS: Add myself and Zhensong Liu
+ as the LoongArch maintainer.
+
+2021-12-02 Nick Clifton <nickc@redhat.com>
+
+ PR 28645
+ * dwarf.c (process_cu_tu_index): Add test for overruning section
+ whilst processing slots.
+
+2021-11-30 Roland McGrath <mcgrathr@google.com>
+
+ * doc/local.mk: Give each man page target its missing dependency on
+ doc/$(am__dirstamp).
+
+2021-11-30 Nick Clifton <nickc@redhat.com>
+
+ * dwarf.c (find_debug_info_for_offset): Use dwarf_vma type for
+ offsets, sizes and ranges.
+ (display_loc_list): Likewise. Also use print_dwarf_vma to print
+ the offset.
+ (display_loclists_list): Likewise.
+ (display_loc_list_dwo): Likewise.
+ (display_debug_str): Likewise.
+ (display_debug_aranges): Likewise.
+ (display_debug_ranges_list): Likewise.
+ (display_debug_rnglists_list): Likewise.
+ (display_debug_ranges): Likewise.
+
+2021-11-29 Nick Clifton <nickc@redhat.com>
+
+ PR 28632
+ * strings.c (usage): Update desciption of -n option.
+ * doc/binutils.texi: Likewise.
+
+2021-11-24 Nick Clifton <nickc@redhat.com>
+
+ PR 28564
+ * sysdump.c (getCHARS): Check for an out of bounds read.
+
+2021-11-16 Fangrui Song <maskray@google.com>
+
+ * readelf.c (enum relocation_type): New.
+ (slurp_relr_relocs): New.
+ (dump_relocations): Change is_rela to rel_type.
+ Dump RELR.
+ (dynamic_relocations): Add DT_RELR.
+ (process_relocs): Check SHT_RELR and DT_RELR.
+ (process_dynamic_section): Store into dynamic_info for
+ DT_RELR/DT_RELRENT/DT_RELRSZ.
+
+2021-11-09 Nick Clifton <nickc@redhat.com>
+
+ * nm.c: Add --unicode option to control how unicode characters are
+ handled.
+ * objdump.c: Likewise.
+ * readelf.c: Likewise.
+ * strings.c: Likewise.
+ * binutils.texi: Document the new feature.
+ * NEWS: Document the new feature.
+ * testsuite/binutils-all/unicode.exp: New file.
+ * testsuite/binutils-all/nm.hex.unicode
+ * testsuite/binutils-all/strings.escape.unicode
+ * testsuite/binutils-all/objdump.highlight.unicode
+ * testsuite/binutils-all/readelf.invalid.unicode
+
+2021-11-03 Tom Tromey <tromey@adacore.com>
+
+ * dwarf.c (display_debug_loc): Use section name in warnings.
+
+2021-10-25 Nick Alcock <nick.alcock@oracle.com>
+
+ * objdump.c (usage): --ctf now has an optional argument.
+ (main): Adjust accordingly.
+ (dump_ctf): Default it.
+ * doc/ctf.options.texi: Adjust.
+
+2021-10-25 Nick Alcock <nick.alcock@oracle.com>
+
+ * objdump.c (usage): --ctf-parent now takes a name, not a section.
+ (dump_ctf): Don't open a separate section; use the parent_name in
+ ctf_dict_open instead. Use ctf_archive_next, not ctf_archive_iter,
+ so we can pass down a member count.
+ (dump_ctf_archive_member): Add the member count; don't return
+ anything. Import parents into children no matter what the
+ parent's name, while still avoiding displaying the header for the
+ common parent name of ".ctf".
+ * readelf.c (usage): Adjust similarly.
+ (dump_section_as_ctf): Likewise.
+ (dump_ctf_archive_member): Likewise. Never stop iterating over
+ archive members, even if ctf_dump of one member fails.
+ * doc/ctf.options.texi: Adjust.
+
+2021-10-19 Nick Clifton <nickc@redhat.com>
+
+ * nm.c (filter_symbols): Test for a NULL name before checking to
+ see if the symbol is __gnu_lto_slim.
+ * objcopy.c (filter_symbols): Likewise.
+
+2021-09-30 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c (filter_symbols): Fail if attempting to dredefine
+ symbols in an LTO object file.
+
+2021-09-27 Nick Alcock <nick.alcock@oracle.com>
+
+ * configure: Regenerate.
+
+2021-09-20 Andrew Burgess <andrew.burgess@embecosm.com>
+
+ * testsuite/binutils-all/riscv/riscv.exp: New file.
+ * testsuite/binutils-all/riscv/unknown.d: New file.
+ * testsuite/binutils-all/riscv/unknown.s: New file.
+
+2021-09-07 Luis Machado <luis.machado@linaro.org>
+
+ Revert: [AArch64] MTE corefile support
+
+ 2021-05-21 Luis Machado <luis.machado@linaro.org>
+
+ * readelf.c (get_note_type): Handle NT_MEMTAG note types.
+
+2021-08-11 Nick Clifton <nickc@redhat.com>
+
+ * po/pt.po: Updated Portuguese translation.
+
+2021-08-10 Nick Clifton <nickc@redhat.com>
+
+ * po/sr.po: Updated Serbian translation.
+
2021-07-16 Nick Clifton <nickc@redhat.com>
* po/sv.po: Updated Swedish translation.
For older changes see ChangeLog-2020
\f
-Copyright (C) 2021 Free Software Foundation, Inc.
+Copyright (C) 2021-2022 Free Software Foundation, Inc.
Copying and distribution of this file, with or without modification,
are permitted in any medium without royalty provided the copyright